stevekm/IGV-snapshot-automator

.Genome file input

Closed this issue · 6 comments

Is there a way to make the .genome file headlessly on the command line? I made a .chrom.sizes file which takes the place of the .genome file but the alignments with annotations would be much preferred.

Thank you.

Jeff

Hi Jeff, I am not entirely clear which genome file you are referring to. However, in my Dockerfile here I show how I load the hg19 genome for the first time;

https://github.com/stevekm/IGV-snapshot-automator/blob/master/Dockerfile#L24-L25

    printf 'new\ngenome hg19\nexit\n' > /genome.bat && \
    xvfb-run --auto-servernum --server-num=1 igv.sh -b /genome.bat

Hi Steve,

Thank you for the quick response and my apologies for being unclear. For the -g option of the script, I currently use the IGV GUI to generate a .genome file, which I use for the alignments. I was just curious if there was a way to do this from the command line since I am generating novel .genome files for different S. cerevisiae clones.

image

I dont think I have ever used a custom genome before, so I am not clear how you would go about supplying that.

The Python script is just a wrapper around the IGV Batch file script;
https://software.broadinstitute.org/software/igv/batch

as per their example, the "genome" is supplied like this;

new
genome hg18
load  myfile.bam
snapshotDirectory mySnapshotDirectory
goto chr1:65,289,335-65,309,335

Its not clear to me if this supports using a genome file or not.

The -g argument to the make_IGV_snapshots.py script is just doing the same thing as shown there, supplying a character string to use in place of the genome. So -g hg19 comes out as genome hg19 in the batch script generated. You might try just supplying it as a file path and seeing if it works.

Hi @jeffwongdmx There is no script to do it, but it should be easy to build one. A ".genome" file is just a zip archive, its described here (along with other info not relevant for this): https://github.com/igvteam/igv/wiki/Hosting-Genomes. To see this just unzip any genome file ("unzip hg19.genome").

@stevekm heads up that the 2.9 release is mainly focused on batch execution, with a lot of effort put into making that more robust. In addition, in the next release you can use json to define reference genomes as described here:
https://github.com/igvteam/igv.js/wiki/Reference-Genome
This json file can be used in place of a ".genome" file.

@stevekm @jeffwongdmx And yes you can use a file path to a ".genome", ".fasta", or other reference definition file (e.g. json in the next release) in lieu of an ID.

I am gonna close this, if there is still an issue present please re-open, thanks