how can I display wig tracks in UCSC browser?
Hi, I have uploaded a 2GB wiggle file to Galaxy. Can I display the Wig track in UCSC genome browser directly via Galaxy? thx Yu Yang
Hi, I am wondering how to handle optional arguments in a tool wrapper for Galaxy. I looked at other wrappers but could not find the way to do the right thing. The <inputs> section of my tool contains: <param name="random_seed" type="integer" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." /> The <command> section looks like: Grinder -random_seed $random_seed However, when I run the tool through the webinterface without specifying a seed value, the jobs starts but fails with the error:
Traceback (most recent call last): File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/runners/local.py", line 56, in run_job job_wrapper.prepare() File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/__init__.py", line 371, in prepare self.command_line = self.tool.build_command_line( param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/tools/__init__.py", line 1525, in build_command_line command_line = fill_template( self.command, context=param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/util/template.py", line 9, in fill_template return str( Template( source=template_text, searchList=[context] ) ) File "/Users/galaxy/galaxy_dist/eggs/Cheetah-2.2.2-py2.6-macosx-10.6-universal-ucs2.egg/Cheetah/Template.py", line 1004, in __str__ return getattr(self, mainMethName)() File "DynamicallyCompiledCheetahTemplate.py", line 168, in respond NotFound: cannot find 'random_seed'
I assume that I need to adjust my <commands> section so that the "-random_seed $random_seed" parameter and values are issued only if $random_seed has been set to a value. Something like: Grinder #if ??? $random_seed ??? -random_seed $random_seed #end if The question is: how to do it? I tried a variety of syntaxes without success. Thanks, Florent
On Sun, Feb 13, 2011 at 8:13 AM, Florent Angly <florent.angly@gmail.com> wrote:
Hi,
I am wondering how to handle optional arguments in a tool wrapper for Galaxy. I looked at other wrappers but could not find the way to do the right thing.
The <inputs> section of my tool contains: <param name="random_seed" type="integer" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." />
The <command> section looks like: Grinder -random_seed $random_seed
However, when I run the tool through the webinterface without specifying a seed value, the jobs starts but fails with the error:
Traceback (most recent call last): File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/runners/local.py", line 56, in run_job job_wrapper.prepare() File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/__init__.py", line 371, in prepare self.command_line = self.tool.build_command_line( param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/tools/__init__.py", line 1525, in build_command_line command_line = fill_template( self.command, context=param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/util/template.py", line 9, in fill_template return str( Template( source=template_text, searchList=[context] ) ) File "/Users/galaxy/galaxy_dist/eggs/Cheetah-2.2.2-py2.6-macosx-10.6-universal-ucs2.egg/Cheetah/Template.py", line 1004, in __str__ return getattr(self, mainMethName)() File "DynamicallyCompiledCheetahTemplate.py", line 168, in respond NotFound: cannot find 'random_seed'
I assume that I need to adjust my <commands> section so that the "-random_seed $random_seed" parameter and values are issued only if $random_seed has been set to a value. Something like:
Grinder #if ??? $random_seed ??? -random_seed $random_seed #end if
The question is: how to do it? I tried a variety of syntaxes without success.
Thanks,
Florent
I don't think it works, see: https://bitbucket.org/galaxy/galaxy-central/issue/403 My patch may still work - I haven't looked at this recently though. Peter
Florent, you should be able to do this using cheetah scripting. Perhaps you can give the seed a specific (nonsense) default value like 0 or -1? You could check on this with cheetah scripting for this value and if so issue the command without additional parameters, otherwise issue the command witht the set values.... hope this helps and was your question.. lex ________________________________________ Van: galaxy-user-bounces@lists.bx.psu.edu [galaxy-user-bounces@lists.bx.psu.edu] namens Florent Angly [florent.angly@gmail.com] Verzonden: zondag 13 februari 2011 9:13 Aan: galaxy-user@lists.bx.psu.edu Onderwerp: [galaxy-user] Optional tool arguments Hi, I am wondering how to handle optional arguments in a tool wrapper for Galaxy. I looked at other wrappers but could not find the way to do the right thing. The <inputs> section of my tool contains: <param name="random_seed" type="integer" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." /> The <command> section looks like: Grinder -random_seed $random_seed However, when I run the tool through the webinterface without specifying a seed value, the jobs starts but fails with the error:
Traceback (most recent call last): File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/runners/local.py", line 56, in run_job job_wrapper.prepare() File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/__init__.py", line 371, in prepare self.command_line = self.tool.build_command_line( param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/tools/__init__.py", line 1525, in build_command_line command_line = fill_template( self.command, context=param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/util/template.py", line 9, in fill_template return str( Template( source=template_text, searchList=[context] ) ) File "/Users/galaxy/galaxy_dist/eggs/Cheetah-2.2.2-py2.6-macosx-10.6-universal-ucs2.egg/Cheetah/Template.py", line 1004, in __str__ return getattr(self, mainMethName)() File "DynamicallyCompiledCheetahTemplate.py", line 168, in respond NotFound: cannot find 'random_seed'
I assume that I need to adjust my <commands> section so that the "-random_seed $random_seed" parameter and values are issued only if $random_seed has been set to a value. Something like: Grinder #if ??? $random_seed ??? -random_seed $random_seed #end if The question is: how to do it? I tried a variety of syntaxes without success. Thanks, Florent _______________________________________________ The Galaxy User list should be used for the discussion of Galaxy analysis and other features on the public server at usegalaxy.org. For discussion of local Galaxy instances and the Galaxy source code, please use the Galaxy Development list: http://lists.bx.psu.edu/listinfo/galaxy-dev To manage your subscriptions to this and other Galaxy lists, please use the interface at: http://lists.bx.psu.edu/
Dear all, I am analyzing a set of miRNA-SEQ data. Many of the reads can be mapped to multiple locations. I want to test two options: divide the counts equally among all possible locations or randomly assign them to one of the the locations. Could anybody please let me know how I can accomplish this? Thanks in advance, JF
Thanks for the help Alex! I got it working this way: In the <inputs> section: <param name="random_seed" type="integer" value="0" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." /> In the <command> section: #if $random_seed > 0 -random_seed $random_seed #end if Florent On 14/02/11 01:04, Bossers, Alex wrote:
Florent, you should be able to do this using cheetah scripting. Perhaps you can give the seed a specific (nonsense) default value like 0 or -1? You could check on this with cheetah scripting for this value and if so issue the command without additional parameters, otherwise issue the command witht the set values....
hope this helps and was your question.. lex
________________________________________ Van: galaxy-user-bounces@lists.bx.psu.edu [galaxy-user-bounces@lists.bx.psu.edu] namens Florent Angly [florent.angly@gmail.com] Verzonden: zondag 13 februari 2011 9:13 Aan: galaxy-user@lists.bx.psu.edu Onderwerp: [galaxy-user] Optional tool arguments
Hi,
I am wondering how to handle optional arguments in a tool wrapper for Galaxy. I looked at other wrappers but could not find the way to do the right thing.
The<inputs> section of my tool contains: <param name="random_seed" type="integer" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." />
The<command> section looks like: Grinder -random_seed $random_seed
However, when I run the tool through the webinterface without specifying a seed value, the jobs starts but fails with the error:
Traceback (most recent call last): File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/runners/local.py", line 56, in run_job job_wrapper.prepare() File "/Users/galaxy/galaxy_dist/lib/galaxy/jobs/__init__.py", line 371, in prepare self.command_line = self.tool.build_command_line( param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/tools/__init__.py", line 1525, in build_command_line command_line = fill_template( self.command, context=param_dict ) File "/Users/galaxy/galaxy_dist/lib/galaxy/util/template.py", line 9, in fill_template return str( Template( source=template_text, searchList=[context] ) ) File "/Users/galaxy/galaxy_dist/eggs/Cheetah-2.2.2-py2.6-macosx-10.6-universal-ucs2.egg/Cheetah/Template.py", line 1004, in __str__ return getattr(self, mainMethName)() File "DynamicallyCompiledCheetahTemplate.py", line 168, in respond NotFound: cannot find 'random_seed' I assume that I need to adjust my<commands> section so that the "-random_seed $random_seed" parameter and values are issued only if $random_seed has been set to a value. Something like:
Grinder #if ??? $random_seed ??? -random_seed $random_seed #end if
The question is: how to do it? I tried a variety of syntaxes without success.
Thanks,
Florent
_______________________________________________ The Galaxy User list should be used for the discussion of Galaxy analysis and other features on the public server at usegalaxy.org. For discussion of local Galaxy instances and the Galaxy source code, please use the Galaxy Development list:
http://lists.bx.psu.edu/listinfo/galaxy-dev
To manage your subscriptions to this and other Galaxy lists, please use the interface at:
On Mon, Feb 14, 2011 at 8:44 AM, Florent Angly <florent.angly@gmail.com> wrote:
Thanks for the help Alex! I got it working this way:
In the <inputs> section: <param name="random_seed" type="integer" value="0" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." />
In the <command> section: #if $random_seed > 0 -random_seed $random_seed #end if
Florent
Does that actually let the user put an empty string in? My guess is not, and you are just using zero as the default (meaning no seed). This is the same workaround I have been using (where there is a suitable dummy values - not always the case). Peter
On 14/02/11 19:35, Peter Cock wrote:
Thanks for the help Alex! I got it working this way:
In the<inputs> section: <param name="random_seed" type="integer" value="0" optional="true" label="Random seed" help="Seed number to use for the pseudo-random number generator." />
In the<command> section: #if $random_seed> 0 -random_seed $random_seed #end if
Florent Does that actually let the user put an empty string in? My guess is not, and you are just using zero as the default (meaning no seed). This is
On Mon, Feb 14, 2011 at 8:44 AM, Florent Angly<florent.angly@gmail.com> wrote: the same workaround I have been using (where there is a suitable dummy values - not always the case).
Peter
Yes, it simply is a workaround that allows me to keep working with Galaxy. Hopefully, your patch that fixes this issue can be accepted soon: https://bitbucket.org/galaxy/galaxy-central/issue/403/enhance-tool-parameter... Best, Florent
participants (5)
-
Bossers, Alex
-
Fang, Jianwen
-
Florent Angly
-
Peter Cock
-
yang yu