For the simplest case, start with the tools/rgenetics/rgFastQC tool - it doesn't need a subclass but uses the Html datatype files_path as a simple multiple file bucket. 
Once you've got that all figured out, check out the rgenetics datatypes (eg pbed) subclassed from Html defined in lib/galaxy/datatypes/genetics and the tools that use it (eg TDT or CaCo tools) in tools/rgenetics for more complex hackery keeping related files needed by plink together.


On Fri, Jan 4, 2013 at 9:50 AM, <Neil.Burdett@csiro.au> wrote:

Thanks for the help Ross.

 

Any chance you can point me to the examples you mentioned?

 

Thanks again

Neil

 

From: Ross [mailto:ross.lazarus@gmail.com]
Sent: Friday, 4 January 2013 8:35 AM


To: Burdett, Neil (ICT Centre, Herston - RBWH)
Cc: galaxy-user
Subject: Re: [galaxy-user] Upload files from filesystem paths

 

Hi, Neal,

Thanks - that sounds interesting. Like I said, composite datatypes are designed to manage collections of related files as a unit and this sounds like a potential use case. There are lots of tools and lots of code that can serve as examples but it's definitely not trivial because you will almost certainly be subclassing the Html data class and writing methods to manage those related files (ie extending the guts of Galaxy) and your tools will all need to know how to deal with the managed structure when they get one as an input. 

 

You may need to find or build up a programmer with some relevant Galaxy composite datatype experience. There is some documentation but it's not extensive or transparent. 

 

Good luck.

 

On Fri, Jan 4, 2013 at 9:19 AM, <Neil.Burdett@csiro.au> wrote:

Hi Ross,

             I don’t know of any tools that work in the way I want, but I’m not an expert on tools within Galaxy. Essentially the data in the directories will be fixed. We run a tool from Galaxy that generates some output data, this data then “checks” the data located under the directories I am trying to upload to Galaxy. There will probably be around 20 directories, and the data produced would then search these directories looking for “a closest match” once located it would use the remaining files in the directory to complete the process.

 

So for example, the application is segmenting an image, so a part of the image is the output. This is compared with files in the uploaded directories and a file in a particular directory is chosen (as the closest match) then the remaining files in the directory are then used to complete the process.

 

Does that make sense? There would be around 20 files in each directory.

 

Thanks

Neil

 

From: Ross [mailto:ross.lazarus@gmail.com]
Sent: Thursday, 3 January 2013 2:24 PM


To: Burdett, Neil (ICT Centre, Herston - RBWH)
Cc: galaxy-user
Subject: Re: [galaxy-user] Upload files from filesystem paths

 

Neil, 

It would help if you could point to an existing tool that works the way you want. I don't know of any that deal with arbitrary nested directories containing arbitrary files. A new composite datatype could impose a structure that a tool could be written to deal with (eg the pbed datatype used in some rgenetics tools) but arbitrary data structures are not going to be possible AFAIK. You're unlikely to get useful help without a much more complete and clear explanation of the problem.

 

 

On Thu, Jan 3, 2013 at 1:50 PM, <Neil.Burdett@csiro.au> wrote:

Hi Ross,
             I think I need to clarify. I have a file in /home/galaxy/data-test/dir1/dir2/somefile.txt

Under the "Upload files from filesystem paths", In the "path to upload" window I paste "/home/galaxy/data-test". This then puts the "somefile.txt" in the /home/galaxy/galaxy-dist/database/files/000 directory. However, I elected to keep the directory structure. I can see this if I navigate through the "shared data" tab but where is this information stored under the galaxt-dist structure. As my application needs to have the directory structure kept, so need to access it from the xml/command line

I thought it might have been something like: /home/galaxy/galaxy-dist/database/files/000/data-test/dir1/dir2/dataset_id.dat. But this is not the case rather  /home/galaxy/galaxy-dist/database/files/000/dataset_id.dat. i.e. no directory structure. So how can I access this information from the xml files in the tools directory?

Thanks
Neil
________________________________________
From: Ross [ross.lazarus@gmail.com]
Sent: Wednesday, January 02, 2013 4:43 PM
To: Burdett, Neil (ICT Centre, Herston - RBWH)
Cc: galaxy-user
Subject: Re: [galaxy-user] Upload files from filesystem paths


Try importing those library files to the history where you want them - browse the Galaxy 'shared data' tab to where you uploaded them.

On Wed, Jan 2, 2013 at 11:39 AM, <Neil.Burdett@csiro.au<mailto:Neil.Burdett@csiro.au>> wrote:
Hi,
   I have a local galaxy installation.

I've created a data library, selected "Upload files from filesystem paths", pasted a path in the "path to upload" window, and I've selected to preserve the directory structure". And the files get imported.

How do I now access these files from my application? I don't want to import them into the history as then they lose the directory structure. I can't see where they are physically under the galaxy-dist structure

Thanks for any help

Neil