pygsti.report.convert
This module defines type-differentiation for low level formatting types.
Its main function, convert, takes any item x, a specs dictionary, and a format (ie ‘html’) and returns a formatted version of x using the format
Module Contents
Functions
|
Create a dictionary of the functions in a module |
|
Calculate the dimension of some matrix-like type |
|
Differentiate an item's type |
|
Convert any item to a format |
|
Create a converter function for some specific format |
Attributes
- pygsti.report.convert.functions_in(module)
Create a dictionary of the functions in a module
Parameters
- moduleModule
module to run on.
Returns
dict
- pygsti.report.convert.convert_dict
- pygsti.report.convert.calc_dim(x)
Calculate the dimension of some matrix-like type
Parameters
- xmatrix-like
The object to get the dimension of.
Returns
int
- pygsti.report.convert.item_type(x)
Differentiate an item’s type
Parameters
- xanything
Value to convert.
Returns
- string
name of low-level formatter to use (i.e. value or matrix)