You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am working with OpenWorm to generate automatically the ion channels used for the parameters C for the neurons. One of the gates used is a custom type that doesn't exist in NeuroML, which works with the simulation when looking like this (only the first parameter alpha matters here) :
However, when generated with NeuroML, the dimension of alpha is not written as it is none, and one obtains the following (only the parameter alpha changed) :
I agree it's an issue that the dimension="none" is not written. This is probably down to this line where the default value for dimension is set to none. The generated API then decides that there is no need to print that attribute, as it's the same as the default.
One option for you would be to try the PyLEMS API; another would be to write that definition in its own text file and straight after read in and replace that line with one containing dimension="none".
I'll look into removing the default value in the schema and this will fix the issue in the generated APIs, but it may have a knock on effect else where, so would like to test a bit locally first. The other option of fixing jLems (which is ultimately where the issue arises) I can look at too, but in general it's better to have the explicit requirement to specify dimension="none".
Hi,
I am working with OpenWorm to generate automatically the ion channels used for the parameters C for the neurons. One of the gates used is a custom type that doesn't exist in NeuroML, which works with the simulation when looking like this (only the first parameter alpha matters here) :
However, when generated with NeuroML, the dimension of alpha is not written as it is none, and one obtains the following (only the parameter alpha changed) :
The problem is that this leads to an error when running JNeuroML :
pyNeuroML >>> jNeuroML >> (ERROR) no dimension for final param: alpha null
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.logging.E.multiError(E.java:251)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.logging.E.error(E.java:217)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.FinalParam.toString(FinalParam.java:39)
pyNeuroML >>> jNeuroML >> (LOG) at java.lang.String.valueOf(String.java:2994)
pyNeuroML >>> jNeuroML >> (LOG) at java.lang.StringBuilder.append(StringBuilder.java:131)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.ParamValue.setValue(ParamValue.java:53)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.Component.resolve(Component.java:409)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.Component.resolve(Component.java:251)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.Component.resolve(Component.java:238)
pyNeuroML >>> jNeuroML >> (LOG) at org.lemsml.jlems.core.type.Component.checkResolve(Component.java:215)
pyNeuroML >>> jNeuroML >> Exception in thread "main" java.lang.NullPointerException
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.FinalParam.toString(FinalParam.java:41)
pyNeuroML >>> jNeuroML >> at java.lang.String.valueOf(String.java:2994)
pyNeuroML >>> jNeuroML >> at java.lang.StringBuilder.append(StringBuilder.java:131)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.ParamValue.setValue(ParamValue.java:53)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:409)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:251)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:238)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.checkResolve(Component.java:215)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:471)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:251)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.resolve(Component.java:238)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Component.checkResolve(Component.java:215)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.type.Lems.resolve(Lems.java:163)
pyNeuroML >>> jNeuroML >> at org.lemsml.jlems.core.sim.LemsProcess.readModel(LemsProcess.java:82)
pyNeuroML >>> jNeuroML >> at org.neuroml.export.utils.Utils.readLemsNeuroMLFile(Utils.java:256)
pyNeuroML >>> jNeuroML >> at org.neuroml.JNeuroML.loadLemsFile(JNeuroML.java:239)
pyNeuroML >>> jNeuroML >> at org.neuroml.JNeuroML.loadLemsFile(JNeuroML.java:228)
pyNeuroML >>> jNeuroML >> at org.neuroml.JNeuroML.main(JNeuroML.java:453)
Is it possible to update JNeuroML to consider a dimension as none when not specified ?
The text was updated successfully, but these errors were encountered: