A python package that takes an assembly result of a chloroplast genome and continues it by computing the scaffolding stage.
Project description
Khloraa: scaffolding stage
Quick installation
To install the khloraascaf
package from the PyPI repository, run the pip
command :
pip install khloraascaf
You can find more installation details in the docs/src/install.md file.
Quick usage example
from pathlib import Path
from khloraascaf import (
DR_CODE_SUFFIX,
IR_CODE_SUFFIX,
UNIQUE_CODE_SUFFIX,
scaffolding,
)
from khloraascaf.ilp import fmt_cbc_log_name
from khloraascaf.inputs import INSTANCE_NAME_DEF, SOLVER_CBC
from khloraascaf.outputs import (
fmt_contigs_of_regions_filename,
fmt_map_of_regions_filename,
)
#
# Prepare the scaffolding result directory
#
outdir = Path('scaffolding_result')
outdir.mkdir(exist_ok=True)
#
# Compute the scaffolding using the assembly data
#
scaffolding(
Path('tests/data/IR_alone/contigs_attrs.tsv'),
Path('tests/data/IR_alone/contigs_links.tsv'),
'C0',
solver='CBC',
outdir=outdir,
)
#
# See which files the scaffolding has produced:
#
files = set(outdir.glob('*'))
assert len(files) == 5
#
# * The list of oriented contigs for each region
#
assert outdir / fmt_contigs_of_regions_filename(INSTANCE_NAME_DEF) in files
#
# * The list of oriented regions
#
assert outdir / fmt_map_of_regions_filename(INSTANCE_NAME_DEF) in files
#
# * CBC logs for directed repeat scaffolding
#
assert outdir / fmt_cbc_log_name(
f'{INSTANCE_NAME_DEF}_{DR_CODE_SUFFIX}',
) in files
#
# * CBC logs for inverted repeat scaffolding
#
assert outdir / fmt_cbc_log_name(
f'{INSTANCE_NAME_DEF}_{IR_CODE_SUFFIX}',
) in files
#
# * CBC logs for inverted repeat scaffolding then unique region scaffolding
#
assert outdir / fmt_cbc_log_name(
f'{INSTANCE_NAME_DEF}_{IR_CODE_SUFFIX}_{UNIQUE_CODE_SUFFIX}',
) in files
Changelog
You can refer to the docs/src/changelog.md file for details.
What next?
Find a list of ideas in the docs/src/todo.md file.
Contributing
- If you find any errors, missing documentation or test, or you want to discuss features you would like to have, please post an issue (with the corresponding predefined template) here.
- If you want to help me code, please post an issue or contact me. You can find coding convention in the docs/src/contributing.md file.
References
- A part of the scaffolding method is described in this preprint:
📰 Victor Epain, Dominique Lavenier, and Rumen Andonov, ‘Inverted Repeats Scaffolding for a Dedicated Chloroplast Genome Assembler’, 3 June 2022, https://doi.org/10.4230/LIPIcs.
Licence
This work is licensed under a GNU-GPLv3 licence.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
khloraascaf-0.0.0.tar.gz
(64.9 kB
view hashes)
Built Distribution
Close
Hashes for khloraascaf-0.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f3146e50d64f022e6d12d23d07e36e27331e3d20774ba5f5c284a352af1bea9 |
|
MD5 | 4a40b4af46f8b3db5cc6f3d788a1f4b8 |
|
BLAKE2b-256 | 33564623777816a42e65dae5dae5b106934bd0757b17935238b6108c50727b15 |