Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

 getSlice() CPO vs  IDS
Code Block
languagepy
titleITM
linenumberstrue
#system libraries
import sys
import numpy

#UAL library
import ual

#Open the database
itm_obj = ual.itm(11,22)
itm_obj.open() 
 
cpo = my_itm_obj.pfsystems

#Get data
cpo.getSlice(2, 1)

#SCALARS 
print 'Time : ' + str(cpo.time)
print 'VALUE = ' + str(ids.x.y)

#close the pulse file
itm_obj.close()
Code Block
languagepy
titleIMAS
linenumberstrue
#system libraries
import sys
import numpy

#UAL library
import imas

#Open a database
imas_obj = imas.ids(11,22)
imas_obj.open()  

ids = imas_obj.core_profiles

#Get data
ids.getSlice(2, 1)

#SCALARS 
print 'Time : ' + str(ids.time)
print 'VALUE = ' + str(ids.x.y)

#close the pulse file
imas_obj.close()

...