Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] pynml-channelanalysis cannot find include file in same folder (Windows) #110

Open
psyogi-o opened this issue Jun 21, 2021 · 3 comments
Labels
T: bug Type: bug T: question T: question

Comments

@psyogi-o
Copy link

psyogi-o commented Jun 21, 2021

Describe the bug
The sigmoid.offset.xml is in the same exact folder as the ca.slow.channel.nml but pynml channel analysis cannot find path

To Reproduce
Running command pynml-channelanalysis ca.slow.channel.nml

Expected behavior
Just work?

Observed behavior

C:..\NeuroML2>pynml-channelanalysis ca.slow.channel.nml
pyNeuroML >>>
pyNeuroML >>> Analysing channels from files: ['ca.slow.channel.nml']
pyNeuroML >>>
org.lemsml.jlems.core.sim.ContentError: Can't find file at path: C:\sigmoid.offset.xml
Search directories are: [C:..\NeuroML2]
Search paths in jar are: [/NeuroML2CoreTypes]

        at org.lemsml.jlems.io.reader.JarResourceInclusionReader.getRelativeContent(JarResourceInclusionReader.java:179)
        at org.neuroml.export.utils.NeuroMLInclusionReader.getRelativeContent(NeuroMLInclusionReader.java:61)
        at org.lemsml.jlems.core.sim.AbstractInclusionReader.getIncludeContent(AbstractInclusionReader.java:41)
        at org.lemsml.jlems.core.sim.AbstractInclusionReader.insertIncludes(AbstractInclusionReader.java:71)
        at org.neuroml.export.utils.NeuroMLInclusionReader.insertIncludes(NeuroMLInclusionReader.java:102)
        at org.lemsml.jlems.core.sim.AbstractInclusionReader.read(AbstractInclusionReader.java:24)
        at org.neuroml.export.utils.Utils.readLemsNeuroMLFile(Utils.java:259)
        at org.neuroml.export.utils.Utils.readLemsNeuroMLFile(Utils.java:245)
        at org.neuroml.export.utils.Utils$1.importFile(Utils.java:505)
        at org.lemsml.jlems.viz.datadisplay.ControlPanel.initialise(ControlPanel.java:134)
        at org.neuroml.export.utils.Utils.loadLemsFile(Utils.java:516)
        at org.neuroml.export.utils.Utils.runLemsFile(Utils.java:493)
        at org.neuroml.JNeuroML.main(JNeuroML.java:595)
pyNeuroML >>> *** Problem running command:
pyNeuroML >>>        Command 'java -Xmx400M  -jar  "C:\Users\...\AppData\Local\Programs\Python\Python39\Lib\site-packages\pyneuroml\lib\jNeuroML-0.10.3-jar-with-dependencies.jar"  "C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml"  -nogui -I ''' returned non-zero exit status 1.
pyNeuroML >>>  jNeuroML >>   jNeuroML v0.10.3
pyNeuroML >>>  jNeuroML >>  Loading: C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml with jLEMS, NO GUI mode...
pyNeuroML >>>  jNeuroML >>  INFO Jun 21,2021 15:13  (INFO) Loading LEMS file from: C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml
pyNeuroML >>>  jNeuroML >>  INFO Jun 21,2021 15:13  (INFO) Reading from: C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml
pyNeuroML >>>  jNeuroML >>
pyNeuroML >>> Error: execute_command_in_dir returned with output: None

System information:

  • OS: Windows
  • Python version (3.9.5)
  • Version of tools in use (pynml --21.1.1)

Additional context
Files can be found here: https://github.com/RonCalabreseLab/Leech-8Cell-Tutorial-NeuroML/tree/master/NeuroML2

@sanjayankur31
Copy link
Member

Thanks for the bug report @psyogi-o . It works just fine here on my Linux machine, so this is something Windows related. What shell are you using---is that the Windows command prompt for example? Can you please check what the current working directory is? It's looking for the file in C:\sigmoid.offset.xml, so it thinks it's in C:\ rather than the folder you're trying to run it in. Could you run dir etc. in C:..\NeuroML2 to see where that's meant to be?

Also: would you know what ... in C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml implies?

@sanjayankur31 sanjayankur31 added T: bug Type: bug T: question T: question labels Jun 22, 2021
@sanjayankur31 sanjayankur31 changed the title [Bug] pynml-channelanalysis cannot find include file in same folder! [Bug] pynml-channelanalysis cannot find include file in same folder (Windows) Jun 22, 2021
@pgleeson
Copy link
Member

Same here, works fine on Mac. Not sure where the initial Search directories are: [C:..\NeuroML2] comes from... It shouldn't need to search elsewhere for the definitions. Unfortunately the toolchain is not very well tested on Windows...

@cengique
Copy link

Thanks for the bug report @psyogi-o . It works just fine here on my Linux machine, so this is something Windows related. What shell are you using---is that the Windows command prompt for example?

Hi @sanjayankur31 , I think we were in the command prompt for these. @psyogi-o also had Git bash installed and I think we tested in both, but I may be wrong.

Can you please check what the current working directory is? It's looking for the file in C:\sigmoid.offset.xml, so it thinks it's in C:\ rather than the folder you're trying to run it in. Could you run dir etc. in C:..\NeuroML2 to see where that's meant to be?

Yes, we are in the .../NeuroML2/ folder and all the files are in there. It's adding a C:\ at the beginning for some reason.

Also: would you know what ... in C:\Users\...\Documents\GSoC\Leech-8Cell-Tutorial-NeuroML\Leech-8Cell-Tutorial-NeuroML-master\NeuroML2\LEMS_Test_ca_slow_channel.xml implies?

We manually removed some of the private information and replaced with ... for the public Issue. :) I assume the LEMS_Test_ca_slow_channel.xml is a file auto-generated by pyNeuroML? But it's still in the same folder with everything else as far as I can see.

@github-project-automation github-project-automation bot moved this to 🆕 New in NeuroML backlog Oct 2, 2023
@sanjayankur31 sanjayankur31 moved this from 🆕 New to 📋 Backlog in NeuroML backlog Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T: bug Type: bug T: question T: question
Projects
Status: 📋 Backlog
Development

No branches or pull requests

4 participants