Library

class ionworkspipeline.Library

A class to store a library of materials and their parameter values. The library is a dictionary of materials, each of which should be a dictionary with the following keys:

  • “name” (str): the name of the material

  • “description” (str): a description of the material

  • “parameter values” (dict): a dictionary of parameter values for the material

The “parameter values” dictionary should have the parameter names as keys, and the parameter values as values.

The library provides methods to search for materials and parameters.

property materials

Return a list of the materials in the library.

search_materials(name)

Search for materials in the library.

search_parameters(name)

Search for parameters in the library. This will print the parameter values matching the search term for each material in the library.

class ionworkspipeline.Material(material)

A class to store a information about material and its parameter values.

Parameters

materialdict or string

Explicit material dict or string reference to an material in the ionworkspipeline library. If a string is given, the material will be searched for in the library.

The material dict is a dictionary with the following keys:
  • “name” (str): the name of the material

  • “description” (str): a description of the material

  • “parameter values” (dict): a dictionary of parameter values for the material