I have an external disk whose designation includes spaces. I am running
OSX 10.9. I find that the spaces in the path cause the BIo-Formats macro extensions to fail, I tried escaping the spaces, as in: newInputPath = replace(inputPath," ", "\\\\ "); Ext.setId(inputPath); and I tried enclosing the path in square brackets, as in: Ext.setId("["+inputPath+"]"); but neither of these worked. As a workaround, I set up a symlink to the mount point, and then replaced the path, as in: if (indexOf(inputPath,"Seagate Expansion Drive") > 0) { inputPath = replace(inputPath, "Seagate Expansion Drive", "seagate"); } and this works fine, but it is a hack. I prefer one (or both) of two options: 1. Get the extensions to accept the original path with spaces. 2. Get OSX to mount the disk by default with a mount directory whose name does not include spaces. The second option is not about ImageJ, but maybe there are people on this list who knowhow to do that. Thank in advance for your help. --aryeh -- Aryeh Weiss Faculty of Engineering Bar Ilan University Ramat Gan 52900 Israel Ph: 972-3-5317638 FAX: 972-3-7384051 -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Aryeh,
> I find that the spaces in the path cause the BIo-Formats macro > extensions to fail I did not have time to delve into what causes this bug, but perhaps the whole issue could be avoided by using any scripting language besides ImageJ macros? If you did that, you could call the Bio-Formats API directly; see: http://fiji.sc/Bio-Formats#Scripting Regards, Curtis On Tue, Jul 8, 2014 at 4:14 AM, Aryeh Weiss <[hidden email]> wrote: > I have an external disk whose designation includes spaces. I am running > OSX 10.9. > I find that the spaces in the path cause the BIo-Formats macro extensions > to fail, > I tried escaping the spaces, as in: > > newInputPath = replace(inputPath," ", "\\\\ "); > Ext.setId(inputPath); > > and I tried enclosing the path in square brackets, as in: > Ext.setId("["+inputPath+"]"); > > but neither of these worked. > > As a workaround, I set up a symlink to the mount point, and then replaced > the path, as in: > if (indexOf(inputPath,"Seagate Expansion Drive") > 0) { > inputPath = replace(inputPath, "Seagate Expansion Drive", "seagate"); > } > > > and this works fine, but it is a hack. > > I prefer one (or both) of two options: > > 1. Get the extensions to accept the original path with spaces. > 2. Get OSX to mount the disk by default with a mount directory whose name > does not include spaces. > > The second option is not about ImageJ, but maybe there are people on this > list who knowhow to do that. > > Thank in advance for your help. > > --aryeh > > -- > Aryeh Weiss > Faculty of Engineering > Bar Ilan University > Ramat Gan 52900 Israel > > Ph: 972-3-5317638 > FAX: 972-3-7384051 > > > -- > ImageJ mailing list: http://imagej.nih.gov/ij/list.html > -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Aryeh,
> I find that the spaces in the path cause the BIo-Formats macro > extensions to fail I cannot reproduce this problem on my OS X 10.9 system. Running this macro in the Script Editor: https://github.com/openmicroscopy/bioformats/blob/v5.0.2/components/bio-formats-plugins/utils/macros/basicMetadata.txt And selecting a file with path "/Users/curtis/Desktop/foo bar/2 ch ZT.lsm", it prints the metadata to the ImageJ Log window as expected. If you can create a minimal, complete, verifiable example [1], then please pass it on to the Bio-Formats developers using the ome-users mailing list [2]. Regards, Curtis [1] http://stackoverflow.com/help/mcve [2] http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-users/ On Mon, Jul 14, 2014 at 11:36 PM, Aryeh Weiss <[hidden email]> wrote: > Hi Curtis, > > I am starting to migrate to python, but it is still much faster for me to > use (or reuse) parts of scripts which I have already written. It is also > easier for me to give macro scripts to people who ask me for assistance. > > Best regards, > --aryeh > > > On 7/14/14, 11:31 PM, Curtis Rueden wrote: > > Hi Aryeh, > > > I find that the spaces in the path cause the BIo-Formats macro > > extensions to fail > > I did not have time to delve into what causes this bug, but perhaps the > whole issue could be avoided by using any scripting language besides ImageJ > macros? If you did that, you could call the Bio-Formats API directly; see: > http://fiji.sc/Bio-Formats#Scripting > > Regards, > Curtis > > > On Tue, Jul 8, 2014 at 4:14 AM, Aryeh Weiss <[hidden email]> wrote: > >> I have an external disk whose designation includes spaces. I am running >> OSX 10.9. >> I find that the spaces in the path cause the BIo-Formats macro extensions >> to fail, >> I tried escaping the spaces, as in: >> >> newInputPath = replace(inputPath," ", "\\\\ "); >> Ext.setId(inputPath); >> >> and I tried enclosing the path in square brackets, as in: >> Ext.setId("["+inputPath+"]"); >> >> but neither of these worked. >> >> As a workaround, I set up a symlink to the mount point, and then replaced >> the path, as in: >> if (indexOf(inputPath,"Seagate Expansion Drive") > 0) { >> inputPath = replace(inputPath, "Seagate Expansion Drive", "seagate"); >> } >> >> >> and this works fine, but it is a hack. >> >> I prefer one (or both) of two options: >> >> 1. Get the extensions to accept the original path with spaces. >> 2. Get OSX to mount the disk by default with a mount directory whose name >> does not include spaces. >> >> The second option is not about ImageJ, but maybe there are people on this >> list who knowhow to do that. >> >> Thank in advance for your help. >> >> --aryeh >> >> -- >> Aryeh Weiss >> Faculty of Engineering >> Bar Ilan University >> Ramat Gan 52900 Israel >> >> Ph: 972-3-5317638 >> FAX: 972-3-7384051 >> >> >> -- >> ImageJ mailing list: http://imagej.nih.gov/ij/list.html >> > > > > -- > Aryeh Weiss > Faculty of Engineering > Bar Ilan University > Ramat Gan 52900 Israel > > Ph: 972-3-5317638 > FAX: 972-3-7384051 > > > -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
On 7/16/14, 10:14 PM, Curtis Rueden wrote:
> Hi Aryeh, > > > I find that the spaces in the path cause the BIo-Formats macro > > extensions to fail > > I cannot reproduce this problem on my OS X 10.9 system. > > Running this macro in the Script Editor: > > https://github.com/openmicroscopy/bioformats/blob/v5.0.2/components/bio-formats-plugins/utils/macros/basicMetadata.txt > > And selecting a file with path "/Users/curtis/Desktop/foo bar/2 ch > ZT.lsm", it prints the metadata to the ImageJ Log window as expected. > > If you can create a minimal, complete, verifiable example [1], then > please pass it on to the Bio-Formats developers using the ome-users > mailing list [2]. > > Regards, > Curtis > > [1] http://stackoverflow.com/help/mcve > [2] http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-users/ > > Hi Curtis, I will try to provide a minimal script. However, it occurs to me that this may be related to my disk being NTFS and mounted by OSX-FUSE. Best regards, --aryeh > On Mon, Jul 14, 2014 at 11:36 PM, Aryeh Weiss <[hidden email] > <mailto:[hidden email]>> wrote: > > Hi Curtis, > > I am starting to migrate to python, but it is still much faster > for me to use (or reuse) parts of scripts which I have already > written. It is also easier for me to give macro scripts to people > who ask me for assistance. > > Best regards, > --aryeh > > > On 7/14/14, 11:31 PM, Curtis Rueden wrote: >> Hi Aryeh, >> >> > I find that the spaces in the path cause the BIo-Formats macro >> > extensions to fail >> >> I did not have time to delve into what causes this bug, but >> perhaps the whole issue could be avoided by using any scripting >> language besides ImageJ macros? If you did that, you could call >> the Bio-Formats API directly; see: >> http://fiji.sc/Bio-Formats#Scripting >> >> Regards, >> Curtis >> >> >> On Tue, Jul 8, 2014 at 4:14 AM, Aryeh Weiss <[hidden email] >> <mailto:[hidden email]>> wrote: >> >> I have an external disk whose designation includes spaces. I >> am running OSX 10.9. >> I find that the spaces in the path cause the BIo-Formats >> macro extensions to fail, >> I tried escaping the spaces, as in: >> >> newInputPath = replace(inputPath," ", "\\\\ "); >> Ext.setId(inputPath); >> >> and I tried enclosing the path in square brackets, as in: >> Ext.setId("["+inputPath+"]"); >> >> but neither of these worked. >> >> As a workaround, I set up a symlink to the mount point, and >> then replaced the path, as in: >> if (indexOf(inputPath,"Seagate Expansion Drive") > 0) { >> inputPath = replace(inputPath, "Seagate Expansion Drive", >> "seagate"); >> } >> >> >> and this works fine, but it is a hack. >> >> I prefer one (or both) of two options: >> >> 1. Get the extensions to accept the original path with spaces. >> 2. Get OSX to mount the disk by default with a mount >> directory whose name does not include spaces. >> >> The second option is not about ImageJ, but maybe there are >> people on this list who knowhow to do that. >> >> Thank in advance for your help. >> >> --aryeh >> >> -- >> Aryeh Weiss >> Faculty of Engineering >> Bar Ilan University >> Ramat Gan 52900 Israel >> >> Ph: 972-3-5317638 >> FAX: 972-3-7384051 >> >> >> -- >> ImageJ mailing list: http://imagej.nih.gov/ij/list.html >> >> > > > -- > Aryeh Weiss > Faculty of Engineering > Bar Ilan University > Ramat Gan 52900 Israel > > Ph: 972-3-5317638 > FAX: 972-3-7384051 > > -- Aryeh Weiss Faculty of Engineering Bar Ilan University Ramat Gan 52900 Israel Ph: 972-3-5317638 FAX: 972-3-7384051 -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
In reply to this post by ctrueden
On 7/16/14, 10:14 PM, Curtis Rueden wrote:
> Hi Aryeh, > > > I find that the spaces in the path cause the BIo-Formats macro > > extensions to fail > > I cannot reproduce this problem on my OS X 10.9 system. > > Running this macro in the Script Editor: > > https://github.com/openmicroscopy/bioformats/blob/v5.0.2/components/bio-formats-plugins/utils/macros/basicMetadata.txt > > And selecting a file with path "/Users/curtis/Desktop/foo bar/2 ch > ZT.lsm", it prints the metadata to the ImageJ Log window as expected. > > If you can create a minimal, complete, verifiable example [1], then > please pass it on to the Bio-Formats developers using the ome-users > mailing list [2]. > > Regards, > Curtis > > [1] http://stackoverflow.com/help/mcve > [2] http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-users/ > Hi Curtis I made a mistake in my question -- the problem was not in the extension -- it was in the Bio-Formats importer. run("Bio-Formats Importer", "open="+inputPath+" autoscale color_mode=Default view=Hyperstack stack_order=XYCZT series_1"); failed. However, run("Bio-Formats Importer", "open=["+inputPath+"] autoscale color_mode=Default view=Hyperstack stack_order=XYCZT series_1"); worked. I failed to see this because I thought that the problem was in the extensions. My mistake -- sorry about that. --aryeh > > On Mon, Jul 14, 2014 at 11:36 PM, Aryeh Weiss <[hidden email] > <mailto:[hidden email]>> wrote: > > Hi Curtis, > > I am starting to migrate to python, but it is still much faster > for me to use (or reuse) parts of scripts which I have already > written. It is also easier for me to give macro scripts to people > who ask me for assistance. > > Best regards, > --aryeh > > > On 7/14/14, 11:31 PM, Curtis Rueden wrote: >> Hi Aryeh, >> >> > I find that the spaces in the path cause the BIo-Formats macro >> > extensions to fail >> >> I did not have time to delve into what causes this bug, but >> perhaps the whole issue could be avoided by using any scripting >> language besides ImageJ macros? If you did that, you could call >> the Bio-Formats API directly; see: >> http://fiji.sc/Bio-Formats#Scripting >> >> Regards, >> Curtis >> >> >> On Tue, Jul 8, 2014 at 4:14 AM, Aryeh Weiss <[hidden email] >> <mailto:[hidden email]>> wrote: >> >> I have an external disk whose designation includes spaces. I >> am running OSX 10.9. >> I find that the spaces in the path cause the BIo-Formats >> macro extensions to fail, >> I tried escaping the spaces, as in: >> >> newInputPath = replace(inputPath," ", "\\\\ "); >> Ext.setId(inputPath); >> >> and I tried enclosing the path in square brackets, as in: >> Ext.setId("["+inputPath+"]"); >> >> but neither of these worked. >> >> As a workaround, I set up a symlink to the mount point, and >> then replaced the path, as in: >> if (indexOf(inputPath,"Seagate Expansion Drive") > 0) { >> inputPath = replace(inputPath, "Seagate Expansion Drive", >> "seagate"); >> } >> >> >> and this works fine, but it is a hack. >> >> I prefer one (or both) of two options: >> >> 1. Get the extensions to accept the original path with spaces. >> 2. Get OSX to mount the disk by default with a mount >> directory whose name does not include spaces. >> >> The second option is not about ImageJ, but maybe there are >> people on this list who knowhow to do that. >> >> Thank in advance for your help. >> >> --aryeh >> >> -- >> Aryeh Weiss >> Faculty of Engineering >> Bar Ilan University >> Ramat Gan 52900 Israel >> >> Ph: 972-3-5317638 >> FAX: 972-3-7384051 >> >> >> -- >> ImageJ mailing list: http://imagej.nih.gov/ij/list.html >> >> > > > -- > Aryeh Weiss > Faculty of Engineering > Bar Ilan University > Ramat Gan 52900 Israel > > Ph: 972-3-5317638 > FAX: 972-3-7384051 > > -- Aryeh Weiss Faculty of Engineering Bar Ilan University Ramat Gan 52900 Israel Ph: 972-3-5317638 FAX: 972-3-7384051 -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Free forum by Nabble | Edit this page |