1414import traceback
1515
1616
17- from netpyne import specs , sim , analysis , utils
18- from netpyne .metadata import metadata , api
17+ from netpyne import specs , sim , analysis
18+ from netpyne .specs .utils import validateFunction
19+ from netpyne .conversion .neuronPyHoc import mechVarList
20+ from netpyne .metadata import metadata
1921from netpyne_ui .netpyne_model_interpreter import NetPyNEModelInterpreter
2022from pygeppetto .model .model_serializer import GeppettoModelSerializer
2123import matplotlib .pyplot as plt
@@ -286,14 +288,14 @@ def getAvailableSynMech(self):
286288 return list (netParams .synMechParams .keys ())
287289
288290 def getAvailableMechs (self ):
289- mechs = utils . mechVarList ()['mechs' ]
291+ mechs = mechVarList ()['mechs' ]
290292 for key in list (mechs .keys ()):
291293 if 'ion' in key : del mechs [key ]
292294 for key in ["morphology" , "capacitance" , "extracellular" ]: del mechs [key ]
293295 return list (mechs .keys ())
294296
295297 def getMechParams (self , mechanism ):
296- params = utils . mechVarList ()['mechs' ][mechanism ]
298+ params = mechVarList ()['mechs' ][mechanism ]
297299 return [value [:- (len (mechanism ) + 1 )] for value in params ]
298300
299301 def getAvailablePlots (self ):
@@ -309,7 +311,7 @@ def deleteParam(self, paramToDel):
309311 logging .debug ('Parameter ' + paramToDel + ' is null, not deleted' )
310312
311313 def validateFunction (self , functionString ):
312- return utils . ValidateFunction (functionString , netParams .__dict__ )
314+ return ValidateFunction (functionString , netParams .__dict__ )
313315
314316 def generateScript (self , metadata ):
315317 def convert2bool (string ):
@@ -485,7 +487,7 @@ def GeppettoInit():
485487
486488GeppettoJupyterModelSync .current_model .original_model = json .dumps ({'netParams' : netParams .__dict__ ,
487489 'simConfig' : simConfig .__dict__ ,
488- 'metadata' : metadata . metadata ,
490+ 'metadata' : metadata ,
489491 'requirement' : 'from netpyne_ui.netpyne_geppetto import *' ,
490492 'isDocker' : os .path .isfile ('/.dockerenv' ),
491493 'currentFolder' : os .getcwd ()})
0 commit comments