web
You’re offline. This is a read only version of the page.
close
Thermo Fisher Scientific > Electron Microscopy > Electron Microscopes > 3D Visualization, Analysis and EM Software > Customer Portal > Support Center

VISUALIZATION AND DATA SOLUTIONS

CUSTOMER SUPPORT CENTER

Views:

[Amira 3D / Avizo 3D]

 

Context

In the application, most object properties are accessible through the Properties panel and can also be accessed via scripting using Tcl and Python.

The consoles are:

  • Main Python Console
  • Tcl Console

They allow you to directly retrieve and modify the public properties of the objects.

 

Description

Let's create a simple workflow using a gray image and the Interactive Thresholding.

To explore the scripting properties:

1. Open the Consoles panel using Ctrl+Alt+A.

2. Select the module icon you want to inspect.

3. Choose the appropriate console based on the scripting language.

4. With the console in focus, press the Tab key to auto-complete the module name.

5. Press Enter to display all available properties of the selected module.

Below are examples for each console type:

A. Python Console Example

1. Object properties

2. Object Python API documentation

3. Object ports.

To retrieve object properties (referred to as ports in the scripting language), two common commands are used: portnames and ports.
The portnames command lists all available port names, while the ports command provides access to individual ports.
For more detailed information about a specific port, the help() function can also be used.

 

B. Tcl Console Example

1. Object Properties.
Type the object name in the console and press Enter to display the available commands.
Additionally, the getTypeId method can be used to retrieve the object type:

 

2. Object ports.
This is equivalent to the Python see the preview below the image.

 

Notes

Be careful when working with Tcl scripts, as the language is string-based. If an object name or label contains spaces, it must be enclosed in quotes when used in a script. 

For example, to access Interactive Thresholding in a script, both of the following methods are valid:

 

Related Links

For multiple modules, generally related to image processing (for example, Hysteresis Thresholding), the API differs because these are Visilog modules.

More information about accessing these modules through the API is available in the following knowledge article: KA-01201 / Creating and Modifying Visilog Modules in Avizo/Amira.

These modules can be identified by their type being reported as HxQuant2GenericModule in both the Tcl and Python APIs.