File: Detangle2.py

package info (click to toggle)
shasta 0.14.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 29,636 kB
  • sloc: cpp: 82,262; python: 2,348; makefile: 222; sh: 143
file content (27 lines) | stat: -rw-r--r-- 802 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/python3

import shasta
import argparse

# Parse the arguments.
parser = argparse.ArgumentParser(description=
    'Assembly graph detangling using path following.')    
parser.add_argument('stage', type=str)
parser.add_argument('component', type=int)
arguments = parser.parse_args()
stage = arguments.stage
component = arguments.component

# Get Shasta options.
options = shasta.AssemblerOptions('shasta.conf')

# Create the Assembler and access what we need.
assembler = shasta.Assembler()
assembler.accessMarkers()
assembler.accessMode3Assembler()

# Create the mode3::AssemblyGraph for this assembly stage and component.
assemblyGraph = shasta.Mode3AssemblyGraph(stage, component, assembler, options.assemblyOptions.mode3Options)

# Detangle with path following.
assemblyGraph.detangle2()