pygmi.pfmod.datatypes#
Class for data types.
Classes#
Lithological Model Data. |
Module Contents#
- class pygmi.pfmod.datatypes.LithModel#
Lithological Model Data.
This is the main data structure for the modelling program
- mlut#
colour table for lithologies
- Type:
dictionary
- numx#
number of columns per layer in model
- Type:
int
- numy#
number of rows per layer in model
- Type:
int):
- numz#
number of layers in model
- Type:
int
- dxy#
dimension of cubes in the x and y directions
- Type:
float
- d_z#
dimension of cubes in the z direction
- Type:
float
- lith_index#
3D array of lithological indices.
- Type:
numpy array
- xrange#
minimum and maximum x coordinates
- Type:
list
- yrange#
minimum and maximum y coordinates
- Type:
list
- zrange#
minimum and maximum z coordinates
- Type:
list
- griddata#
dictionary of Data classes with raster data
- Type:
dictionary
- custprofx#
custom profile x coordinates
- Type:
dictionary
- custprofy#
custom profile y coordinates
- Type:
dictionary
- profpics#
profile pictures
- Type:
dictionary
- lith_list#
list of lithologies
- Type:
dictionary
- lith_list_reverse#
reverse lookup for lith_list
- Type:
dictionary
- mht#
height of magnetic sensor
- Type:
float
- ght#
height of gravity sensor
- Type:
float
- gregional#
gravity regional correction
- Type:
float
- lithold_to_lith(nodtm=False, pbar=None)#
Transfers an old lithology to the new one, using update parameters.
- Parameters:
nodtm (bool, optional) – Flag for a DTM. The default is False.
pbar (pygmi.misc.ProgressBar, optional) – Progressbar. The default is None.
- Return type:
None.
- dtm_to_lith(pbar=None)#
Assign the DTM to the model.
This means creating nodata values in areas above the DTM. These values are assigned a lithology of -1.
- Parameters:
pbar (pygmi.misc.ProgressBar, optional) – Progressbar. The default is None.
- Return type:
None.
- init_grid(data)#
Initialize raster variables in the Data class.
- Parameters:
data (numpy array) – Masked array containing raster data.
- Returns:
grid – PyGMI raster dataset.
- Return type:
- init_calc_grids()#
Initialize mag and gravity from the model.
- Return type:
None.
- is_modified(modified=True)#
Update modified flag.
- Parameters:
modified (bool, optional) – Flag for whether the lithology has been modified. The default is True.
- Return type:
None.
- update(cols, rows, layers, utlx, utly, utlz, dxy, d_z, mht=-1, ght=-1, usedtm=True, pbar=None)#
Update the local variables for the LithModel class.
- Parameters:
cols (int) – Number of columns per layer in model.
rows (int) – Number of rows per layer in model.
layers (int) – Number of layers in model.
utlx (float) – Upper top left (NW) x coordinate.
utly (float) – Upper top left (NW) y coordinate.
utlz (float) – Upper top left (NW) z coordinate.
dxy (float) – Dimension of cubes in the x and y directions.
d_z (float) – Dimension of cubes in the z direction.
mht (float, optional) – Height of magnetic sensor. The default is -1.
ght (float, optional) – Height of gravity sensor. The default is -1.
usedtm (bool, optional) – Flag to use a DTM. The default is True.
pbar (pygmi.misc.ProgressBar, optional) – Progressbar. The default is None.
- Return type:
None.
- update_lithlist()#
Update lith_list from local variables.
- Return type:
None.
- update_lith_list_reverse()#
Update the lith_list reverse lookup.
It must be run at least once before using lith_list_reverse.
- Return type:
None.