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

Automatically fetch .csi index from file name #4705

Open
skranz0 opened this issue Dec 9, 2024 · 4 comments
Open

Automatically fetch .csi index from file name #4705

skranz0 opened this issue Dec 9, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@skranz0
Copy link

skranz0 commented Dec 9, 2024

Is your feature request related to a problem? Please describe.

I am working with rather big genomes which cannot be indexed as a .bai and need .csi. While jbrowse automatically fetches index files when you load a .bam, it does not detect .csi files.

Describe the solution you'd like

When loading a alignment.bam, look for a alignment.bam.csi automatically.

Describe alternatives you've considered

I can explicitly load the .csi index, but it would save a few clicks and be a quality of life change if that wasn't necessary.

Additional context

I use JBrowse 2.17.0

@skranz0 skranz0 added the enhancement New feature or request label Dec 9, 2024
@cmdcolin
Copy link
Collaborator

cmdcolin commented Dec 9, 2024

This is generally a nice idea but it would be a little tricky to make this work properly. Just curious, are you generally using the GUI or the CLI for loading tracks? Ideally we would handle either case similarly, but currently they are sort of separate systems

@skranz0
Copy link
Author

skranz0 commented Dec 10, 2024

Naively, I would have thought it would just need to extend some regex for the new file type. I don't know how the internals work, though.
I usually use the GUI, but I'm also not using JBrowse to its full extent, just to double-check coordinates and gene positions from time to time.

@cmdcolin
Copy link
Collaborator

it currently does something like this to automatically fetch .tbi files. to handle .csi it would probably have to first try the .tbi file path, detect a 404, and then try .csi, which could also 404, and then report an error to the user. i think samtools does something like this

@cmdcolin
Copy link
Collaborator

note that my above is just my limited understanding of the issue. if you have a different sequence of operations that you are envisioning, please lay them out in as much detail as possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants