help with slicer.util.loadScalarOverlay

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

help with slicer.util.loadScalarOverlay

Inge Kasbohm Amlien
Hi list, 
I am trying to load a bunch ov overlays from freesurfer (.mgh) onto a model. 

slicer.util.loadScalarOverlay("filename.mgh")
returns "false"

Any tips? How do I tell which model to load it onto?

Cheers
Inge

_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject
Reply | Threaded
Open this post in threaded view
|

Re: help with slicer.util.loadScalarOverlay

Julien Finet
To be able to load, a scalar overlay needs to be given a model.

  from slicer import app
  from vtk import vtkCollection
  properties = {'fileName':SCALAR_OVERLAY_FILE_PATH, 'modelNodeId':ID_OF_THE_MODEL_NODE}
  success = app.coreIOManager().loadNodes(filetype, properties)

slicer.util.loadScalarOverlay in util.py should probably be improved to support a model node ID

Julien.

On Wed, Jul 4, 2012 at 11:03 AM, Inge Kasbohm Amlien <[hidden email]> wrote:
Hi list, 
I am trying to load a bunch ov overlays from freesurfer (.mgh) onto a model. 

slicer.util.loadScalarOverlay("filename.mgh")
returns "false"

Any tips? How do I tell which model to load it onto?

Cheers
Inge

_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject


_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject
Reply | Threaded
Open this post in threaded view
|

Re: help with slicer.util.loadScalarOverlay

Jean-Christophe Fillion-Robin
Hi Inge, 

If adding the convenient function that Julien talks about is something of interest. 
We would be happy to discuss and integrate any patch :)

Thanks
Jc

On Wed, Jul 4, 2012 at 12:43 PM, Julien Finet <[hidden email]> wrote:
To be able to load, a scalar overlay needs to be given a model.

  from slicer import app
  from vtk import vtkCollection
  properties = {'fileName':SCALAR_OVERLAY_FILE_PATH, 'modelNodeId':ID_OF_THE_MODEL_NODE}
  success = app.coreIOManager().loadNodes(filetype, properties)

slicer.util.loadScalarOverlay in util.py should probably be improved to support a model node ID

Julien.

On Wed, Jul 4, 2012 at 11:03 AM, Inge Kasbohm Amlien <[hidden email]> wrote:
Hi list, 
I am trying to load a bunch ov overlays from freesurfer (.mgh) onto a model. 

slicer.util.loadScalarOverlay("filename.mgh")
returns "false"

Any tips? How do I tell which model to load it onto?

Cheers
Inge

_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject




--
+1 919 869 8849


_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject
Reply | Threaded
Open this post in threaded view
|

Re: help with slicer.util.loadScalarOverlay

Inge Kasbohm Amlien
Thanks to both of you. 

I am a python novice, so I believe contributing patches is a bit far up the road yet for me :) If the work results in something useable for others I will surely post it to the list. 

And brace yourselves for more questions

Cheers
Inge

On Jul 4, 2012, at 11:52 PM, Jean-Christophe Fillion-Robin wrote:

Hi Inge, 

If adding the convenient function that Julien talks about is something of interest. 
We would be happy to discuss and integrate any patch :)

Thanks
Jc

On Wed, Jul 4, 2012 at 12:43 PM, Julien Finet <[hidden email]> wrote:
To be able to load, a scalar overlay needs to be given a model.

  from slicer import app
  from vtk import vtkCollection
  properties = {'fileName':SCALAR_OVERLAY_FILE_PATH, 'modelNodeId':ID_OF_THE_MODEL_NODE}
  success = app.coreIOManager().loadNodes(filetype, properties)

slicer.util.loadScalarOverlay in util.py should probably be improved to support a model node ID

Julien.

On Wed, Jul 4, 2012 at 11:03 AM, Inge Kasbohm Amlien <[hidden email]> wrote:
Hi list, 
I am trying to load a bunch ov overlays from freesurfer (.mgh) onto a model. 

slicer.util.loadScalarOverlay("filename.mgh")
returns "false"

Any tips? How do I tell which model to load it onto?

Cheers
Inge

_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject




--
+1 919 869 8849



_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject
Reply | Threaded
Open this post in threaded view
|

Re: help with slicer.util.loadScalarOverlay

Jean-Christophe Fillion-Robin
Hi Inge, 

No problem.

All of that said, if you find yourself writing 5/10 lines of code when you believe that only one would make things more clear, make sure to ping the list and enter a bug in the tracker.

Hth
Jc

On Fri, Jul 6, 2012 at 3:54 AM, Inge Kasbohm Amlien <[hidden email]> wrote:
Thanks to both of you. 

I am a python novice, so I believe contributing patches is a bit far up the road yet for me :) If the work results in something useable for others I will surely post it to the list. 

And brace yourselves for more questions

Cheers
Inge

On Jul 4, 2012, at 11:52 PM, Jean-Christophe Fillion-Robin wrote:

Hi Inge, 

If adding the convenient function that Julien talks about is something of interest. 
We would be happy to discuss and integrate any patch :)

Thanks
Jc

On Wed, Jul 4, 2012 at 12:43 PM, Julien Finet <[hidden email]> wrote:
To be able to load, a scalar overlay needs to be given a model.

  from slicer import app
  from vtk import vtkCollection
  properties = {'fileName':SCALAR_OVERLAY_FILE_PATH, 'modelNodeId':ID_OF_THE_MODEL_NODE}
  success = app.coreIOManager().loadNodes(filetype, properties)

slicer.util.loadScalarOverlay in util.py should probably be improved to support a model node ID

Julien.

On Wed, Jul 4, 2012 at 11:03 AM, Inge Kasbohm Amlien <[hidden email]> wrote:
Hi list, 
I am trying to load a bunch ov overlays from freesurfer (.mgh) onto a model. 

slicer.util.loadScalarOverlay("filename.mgh")
returns "false"

Any tips? How do I tell which model to load it onto?

Cheers
Inge

_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject




--
<a href="tel:%2B1%20919%20869%208849" value="+19198698849" target="_blank">+1 919 869 8849





--
+1 919 869 8849


_______________________________________________
slicer-users mailing list
[hidden email]
http://massmail.spl.harvard.edu/mailman/listinfo/slicer-users
To unsubscribe: send email to [hidden email] with unsubscribe as the subject