# How to get a volume and a model object from in the scene management node?

**URL:** https://discourse.slicer.org/t/how-to-get-a-volume-and-a-model-object-from-in-the-scene-management-node/11338
**Category:** Development
**Created:** [April 29, 2020, 2:54am UTC](https://discourse.slicer.org/t/how-to-get-a-volume-and-a-model-object-from-in-the-scene-management-node/11338 "2020-04-29T02:54:54Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Shicong](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/shicong/32/6562_2.png) [@Shicong](https://discourse.slicer.org/u/Shicong)
#### Post date: [April 29, 2020, 2:54am UTC](https://discourse.slicer.org/t/how-to-get-a-volume-and-a-model-object-from-in-the-scene-management-node/11338/1 "2020-04-29T02:54:54Z")

</div>

This is the case, I loaded a volume and exported a model object, if only one, how to get these two objects in the scene management node! how is implemented in python code?Thanks!

---

<div class="post-metadata">

### Author: ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)
#### Post date: [May 1, 2020, 3:52pm UTC](https://discourse.slicer.org/t/how-to-get-a-volume-and-a-model-object-from-in-the-scene-management-node/11338/2 "2020-05-01T15:52:28Z")

</div>

You can get first instance of a certain MRML node class by calling `slicer.mrmlScene.GetFirstNodeByClass("vtkMRMLVolumeNode")`. However, you should not need this. If input comes from user then you ask the user to make a selection on the GUI. If you process data then you can always set/get the input and output nodes, so you don’t need blind lookup either.
