Previous changeset 4:54396f0323f4 (2024-01-09) Next changeset 6:79f7265f90bd (2024-01-09) |
Commit message:
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/jbrowse2 commit 79e81bef99f582680d9aa4eec88980c675f3fae9 |
modified:
jbrowse2.py jbrowse2.xml macros.xml |
added:
plants.sh |
removed:
tstar.sh |
b |
diff -r 54396f0323f4 -r efc64d8f4b72 jbrowse2.py --- a/jbrowse2.py Tue Jan 09 02:37:42 2024 +0000 +++ b/jbrowse2.py Tue Jan 09 05:24:48 2024 +0000 |
[ |
b'@@ -19,7 +19,7 @@\n log = logging.getLogger("jbrowse")\n TODAY = datetime.datetime.now().strftime("%Y-%m-%d")\n GALAXY_INFRASTRUCTURE_URL = None\n-JB2REL="v2.10.0"\n+JB2REL = "v2.10.0"\n # version pinned for cloning\n \n mapped_chars = {\n@@ -435,16 +435,18 @@\n "displayId": "%s-LinearBasicDisplay" % trackDict["trackId"],\n }\n \n- if trackDict.get("displays", None):\n- style_data["type"] = trackDict["displays"]["type"]\n- style_data["displayId"] = trackDict["displays"]["displayId"]\n- return {"displays": [style_data]}\n+ if trackDict.get("displays", None): # use first if multiple like bed\n+ style_data["type"] = trackDict["displays"][0]["type"]\n+ style_data["displayId"] = trackDict["displays"][0]["displayId"]\n+ return {\n+ "displays": [\n+ style_data,\n+ ]\n+ }\n \n def process_genomes(self):\n assemblies = []\n for i, genome_node in enumerate(self.genome_paths):\n- if self.debug:\n- log.info("genome_node=%s" % str(genome_node))\n genome_name = genome_node["meta"]["dataset_dname"].strip()\n if len(genome_name.split()) > 1:\n genome_name = genome_name.split()[0]\n@@ -550,7 +552,6 @@\n uri: \'https://s3.amazonaws.com/jbrowse.org/genomes/GRCh38/fasta/GRCh38.fa.gz.gzi\',\n Cool will not be likely to be a good fit - see discussion at https://github.com/GMOD/jbrowse-components/issues/2438\n """\n- log.info("#### trackData=%s" % trackData)\n tId = trackData["label"]\n # can be served - if public.\n # dsId = trackData["metadata"]["dataset_id"]\n@@ -579,8 +580,8 @@\n },\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -614,8 +615,6 @@\n dest,\n ]\n self.subprocess_check_call(cmd)\n- if True or self.debug:\n- log.info("### convertMAF.sh called as %s" % " ".join(cmd))\n # Construct samples list\n # We could get this from galaxy metadata, not sure how easily.\n ps = subprocess.Popen(["grep", "^s [^ ]*", "-o", data], stdout=subprocess.PIPE)\n@@ -625,8 +624,6 @@\n soutp = outp.split("\\n")\n samp = [x.split("s ")[1] for x in soutp if x.startswith("s ")]\n samples = [x.split(".")[0] for x in samp]\n- if self.debug:\n- log.info("### got samples = %s " % (samples))\n trackDict = {\n "type": "MafTrack",\n "trackId": tId,\n@@ -644,9 +641,16 @@\n },\n },\n "assemblyNames": [self.genome_name],\n+ "displays": [\n+ {\n+ "type": "LinearBasicDisplay",\n+ "displayId": "%s-LinearBasicDisplay" % tId,\n+ },\n+ {"type": "LinearArcDisplay", "displayId": "%s-LinearArcDisplay" % tId},\n+ ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n if self.config_json.get("plugins", None):\n@@ -714,6 +718,8 @@\n {"type": "LinearArcDisplay", "displayId": "%s-LinearArcDisplay" % tId},\n ],\n }\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -744,8 +750,8 @@\n }\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDi'..b'dest = "%s/%s" % (self.outdir, fname)\n url = fname\n self.subprocess_check_call(["cp", data, dest])\n- log.info("### copied %s to %s" % (data, dest))\n bloc = {"uri": url}\n if bam_index is not None and os.path.exists(os.path.realpath(bam_index)):\n # bai most probably made by galaxy and stored in galaxy dirs, need to copy it to dest\n@@ -792,8 +797,8 @@\n },\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -840,8 +845,8 @@\n },\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -893,8 +898,8 @@\n {"type": "LinearArcDisplay", "displayId": "%s-LinearArcDisplay" % tId},\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -922,14 +927,18 @@\n },\n "displays": [\n {\n+ "type": "LinearPileupDisplay",\n+ "displayId": "%s-LinearPileupDisplay" % tId,\n+ },\n+ {\n "type": "LinearBasicDisplay",\n "displayId": "%s-LinearBasicDisplay" % tId,\n },\n {"type": "LinearArcDisplay", "displayId": "%s-LinearArcDisplay" % tId},\n ],\n }\n- # style_json = self._prepare_track_style(trackDict)\n- # trackDict["style"] = style_json\n+ style_json = self._prepare_track_style(trackDict)\n+ trackDict["style"] = style_json\n self.tracksToAdd.append(trackDict)\n self.trackIdlist.append(tId)\n \n@@ -1151,17 +1160,11 @@\n \n # We need to know the track type from the config.json generated just before\n track_types = {}\n- logging.info("### add default session has data = %s\\n" % str(data))\n with open(self.config_json_file, "r") as config_file:\n config_json = json.load(config_file)\n- logging.info("### config.json read \\n%s\\n" % (config_json))\n \n for track_conf in self.tracksToAdd: # config_json["tracks"]:\n track_types[track_conf["trackId"]] = track_conf["type"]\n- logging.info(\n- "### self.tracksToAdd = %s; track_types = %s"\n- % (str(self.tracksToAdd), str(track_types))\n- )\n \n for on_track in data["visibility"]["default_on"]:\n style_data = {"type": "LinearBasicDisplay", "height": 100}\n@@ -1263,7 +1266,7 @@\n def clone_jbrowse(self):\n """Clone a JBrowse directory into a destination directory."""\n dest = self.outdir\n- cmd = ["jbrowse", "create", "-t",JB2REL, "-f", dest]\n+ cmd = ["jbrowse", "create", "-t", JB2REL, "-f", dest]\n self.subprocess_check_call(cmd)\n for fn in [\n "asset-manifest.json",\n@@ -1437,12 +1440,7 @@\n pass\n track_conf["conf"] = etree_to_dict(track.find("options"))\n jc.add_general_configuration(general_data)\n- print("## processed", str(track_conf), "trackIdlist", jc.trackIdlist)\n x = open(args.xml, "r").read()\n- log.info(\n- "###done processing xml=%s; trackIdlist=%s, config=%s"\n- % (x, jc.trackIdlist, str(jc.config_json))\n- )\n jc.config_json["tracks"] = jc.tracksToAdd\n if jc.usejson:\n jc.write_config()\n' |
b |
diff -r 54396f0323f4 -r efc64d8f4b72 jbrowse2.xml --- a/jbrowse2.xml Tue Jan 09 02:37:42 2024 +0000 +++ b/jbrowse2.xml Tue Jan 09 05:24:48 2024 +0000 |
b |
@@ -997,8 +997,6 @@ can be used to let your users understand relationships between large groups of tracks. -.. image:: sections.png - Annotation Tracks ----------------- @@ -1011,6 +1009,11 @@ These are standard feature tracks. They usually highlight genes, mRNAs and other features of interest along a genomic region. +When these contain tens of millions of features, such as repeat regions from a VGP assembly, displaying one at a time leads +to extremely slow loading times when a large region is in view, unless the "LinearPileupDisplay" display option is +selected for that track in the styling options section. The default is LinearBasicDisplay, which shows all details and works +well for relatively sparse bed files. + BAM Pileups ~~~~~~~~~~~ @@ -1021,8 +1024,6 @@ BlastXML ~~~~~~~~ -.. image:: blast.png - JiG now supports both blastn and blastp datasets. JiG internally uses a blastXML to gapped GFF3 tool to convert your blastxml datasets into a format amenable to visualization in JBrowse. This tool is also @@ -1044,12 +1045,6 @@ **Protein blast search** option merely informs underlying tools that they should adjust feature locations by 3x. -Bigwig XY -~~~~~~~~~ - -.. image:: bigwig.png - - VCFs/SNPs ~~~~~~~~~ |
b |
diff -r 54396f0323f4 -r efc64d8f4b72 macros.xml --- a/macros.xml Tue Jan 09 02:37:42 2024 +0000 +++ b/macros.xml Tue Jan 09 05:24:48 2024 +0000 |
b |
@@ -280,8 +280,8 @@ </xml> <xml name="track_styling_linear"> - <param label="Show labels" name="show_labels" type="boolean" checked="true" truevalue="true" falsevalue="false" /> - <param label="Show descriptions" name="show_descriptions" type="boolean" checked="true" truevalue="true" falsevalue="false" /> + <param label="Show labels" name="show_labels" type="boolean" checked="false" truevalue="true" falsevalue="false" /> + <param label="Show descriptions" name="show_descriptions" type="boolean" checked="false" truevalue="true" falsevalue="false" /> <param name="display_mode" type="select" label="Display mode"> <option value="normal" selected="true">normal</option> <option value="compact">compact</option> @@ -296,8 +296,12 @@ <conditional name="track_style"> <param name="display" type="select" label="Display style" help="How the track will be displayed by default"> <option value="LinearBasicDisplay" selected="true">LinearBasicDisplay</option> + <option value="LinearPileupDisplay">LinearPileupDisplay - good for dense tracks at scale</option> <option value="LinearArcDisplay">LinearArcDisplay</option> </param> + <when value="LinearPileupDisplay"> + <expand macro="track_styling_linear"/> + </when> <when value="LinearBasicDisplay"> <expand macro="track_styling_linear"/> |
b |
diff -r 54396f0323f4 -r efc64d8f4b72 plants.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/plants.sh Tue Jan 09 05:24:48 2024 +0000 |
b |
@@ -0,0 +1,1 @@ +planemo shed_update --shed_target toolshed --owner fubar --name jbrowse2 --shed_key 8d01f2f35d48a0405f72d6d37aedde60 jbrowse2 |
b |
diff -r 54396f0323f4 -r efc64d8f4b72 tstar.sh --- a/tstar.sh Tue Jan 09 02:37:42 2024 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b |
@@ -1,1 +0,0 @@ -tar -cvz --exclude *.gz --exclude *.png jbrowse2/* > jb2.tgz |