Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GFA import #6

Merged
merged 7 commits into from
Sep 6, 2024
Merged

GFA import #6

merged 7 commits into from
Sep 6, 2024

Conversation

dkhofer
Copy link
Collaborator

@dkhofer dkhofer commented Jul 24, 2024

No description provided.

@dkhofer dkhofer requested a review from Chris7 July 25, 2024 17:52
Cargo.toml Outdated
@@ -6,6 +6,7 @@ edition = "2021"
[dependencies]
bio = "2.0.0"
clap = { version = "4.5.8", features = ["derive"] }
gfa-reader = { git = "https://github.com/MoinSebi/gfa-reader", branch = "master" }
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we do a commit hash?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, just added that

Copy link
Collaborator

@Chris7 Chris7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just some random comments on things i think we may have to do.

.sequence_type("DNA")
.sequence(input_sequence)
.save(conn);
sequences_by_segment_id.insert(segment.id, sequence);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we'll probably need to trim this out at larger scale as we won't be able to store all the sequences in memory


for segment in &gfa.segments {
let input_sequence = segment.sequence.get_string(&gfa.sequence);
let sequence = Sequence::new()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what would a shallow version of this look like?

let mut source_hash = Sequence::PATH_START_HASH;
let mut source_coordinate = 0;
let mut path_edge_ids = vec![];
for segment_id in input_walk.walk_id.iter() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this bring any of the strand info with it? walks do have direction

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was being lazy. I'll check what the parser provides and deal with it in a followup PR

@dkhofer dkhofer merged commit a82e41b into main Sep 6, 2024
1 check passed
@Chris7 Chris7 deleted the import-gfa branch September 24, 2024 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants