Skip to content

Datacube

DataCube ¤

Bases: ABC

Base Class Object for datacube. Considered as abstract parent class.

Attributes:

Name Type Description
datacube ndarray

multi-dimensionnal array containing data values.

prefix str

Common name between files.

suffix str

Extension name of the files.

datacube: np.ndarray property ¤

Return data values as a numpy array.

Returns:

Type Description
ndarray

3 dimensionnal numpy array.

prefix: str property ¤

Return prefix.

Returns:

Type Description
str

prefix name.

suffix: str property ¤

Return suffix.

Returns:

Type Description
str

suffix name.

MultiCube ¤

Bases: DataCube

MultiCube Object. MultiCube class is made for discrete datacube such as multispectral satellite data of stack of elemental images.

Attributes:

Name Type Description
data_cube ndarray

multi-dimensionnal array containing data values.

elements Dict

Dictionnary of channel names with associated index.

prefix str

Common name between files.

suffix str

Extension name of the files.

normalization bool

Indication of normalized data (0 to 100).

elements: Dict property ¤

Returns elements dictionnary.

Returns:

Type Description
Dict

Keys are indices and values are element names.

normalization: bool property ¤

Returns Normalization parameters.

Returns:

Type Description
bool

True if Normalized, False else.

MineralCube ¤

Bases: MultiCube

MineralCube Object. MultiCube object where values are binary (0 or 1).

Class essentially made to create mask and make operations between data and masks.

Attributes:

Name Type Description
data_cube ndarrray

multi-dimensionnal array containing data values.

elements Dict

Dictionnary of channel names with associated index.

prefix str

Common name between files.

suffix str

Extension name of the files.

normalization (bool, Optional)

Indication of normalized data (0 to 100).

colors List

Color list provided for plotting consistency.

colors: List property ¤

Returns colors lists.

Returns:

Type Description
List

List of colors for plotting purposes.

map ¤

Create a 2D array that associate each pixel to a mask by assigning a value to each pixel. It also creates a dictionnary containing the relative proportion of a value compared to others.

Returns:

Type Description
ndarray

Tuple containing 2D array to be used as an image,

Dict

and dictionnary containing proportion of each pixel value.

HyperCube ¤

Bases: DataCube

HyperCube Object. HyperCube class is made for continuous datacube such as hyperspecral satellite data or hyperspectral datacube from MicroXRF or EPMA analyses.

Attributes:

Name Type Description
data_cube tbd

HyperSpy object.

prefix str

Filename.

suffix str

File extension.

normalization: bool property ¤

Returns Normalization parameters.

Returns:

Type Description
bool

True if Normalized, False else.