FoldOptLib.fold_modelling package

Submodules

FoldOptLib.fold_modelling.base_fold_frame_builder module

class FoldOptLib.fold_modelling.base_fold_frame_builder.BaseFoldFrameBuilder[source]

Bases: ABC

abstract build_fold_frame(axial_normal: ndarray) None[source]

Build the fold frame

abstract initialise_model()[source]

Setup the bounding box of the fold frame

FoldOptLib.fold_modelling.engine module

class FoldOptLib.fold_modelling.engine.FoldModel(data: DataFrame, bounding_box: list | ndarray, geological_knowledge: Dict[str, Any] | None = None, **kwargs: Dict[str, Any])[source]

Bases: BaseFoldFrameBuilder

A class used to build a fold model.

data

processed data

Type:

pd.DataFrame

bounding_box

bounding box for the model

Type:

list

model

the GeologicalModel object to be built, initialised as None

Type:

Any

gradient_data

gradient data extracted from the data DataFrame

Type:

np.ndarray

points

coordinates of the data points

Type:

np.ndarray

kwargs

additional keyword arguments

Type:

dict

axial_surface

axial surface of the model, initialised as None

Type:

Any

scaled_points

scaled from UTM to the model scale, initialised as None

Type:

Any

No methods defined yet.
build_fold_frame(axial_normal: ndarray) None[source]

Builds a fold frame.

This function processes the axial surface proposition (iteration), updates the model data, creates and adds a fold frame to the model, and then interpolates the fold frame.

Parameters:

axial_normal (np.ndarray) – The axial surface normal vector proposition to be processed.

Return type:

None

calculate_folded_foliation_vectors() ndarray[source]

Calculate the folded foliation vectors.

Returns:

Returns the predicted bedding.

Return type:

List[float]

calculate_svariogram(fold_frame: ndarray, rotation_angles: ndarray) ndarray[source]

Calculates the S-Variogram (semi-variogram) of the fold rotation angles. for more details about the S-Variogram, see Grose et al (2017)

Depending on the keyword arguments ‘axis_wl’ and ‘limb_wl’, this function either returns the initial guess of the fold axis or fold limb rotation angles to optimise a fourier series.

Parameters:
  • fold_frame (np.ndarray) – The fold frame to be used for the semi-variogram calculation.

  • rotation_angles (np.ndarray) – The rotation angles to be used for the semi-variogram calculation.

Returns:

the initial guess for fourier series optimisation.

Return type:

np.ndarray

create_and_build_fold_event() FoldEvent[source]

Creates and builds a fold event.

A fold frame object is first created from the axial surface proposition. The gradient of the axial surface is then calculated and normalised. The fold limb rotation angle is calculated depending on the argument ‘av_fold_axis’. If the argument is set True, the fold limb rotation angle is calculated using the average fold axis. If the argument is set False, the fold limb rotation angle is calculated down a folded fold axis, which is the case of noncylindrical folds.

Returns:

The created fold event.

Return type:

FoldEvent

fit_fourier_series(fold_frame_coordinate: ndarray, rotation_angle: ndarray, knowledge_type: str = 'fold_limb_rotation_angle') List[float][source]

Fit the Fourier series.

Parameters:
  • fold_frame_coordinate (np.ndarray) – The fold frame coordinate.

  • rotation_angle (np.ndarray) – The fold limb or axis rotation angle.

  • knowledge_type (str, optional) – The type of knowledge, use ‘fold_limb_rotation_angle’ or ‘fold_axis_rotation_angle’, by default ‘fold_limb_rotation_angle’.

Returns:

Returns the result of the optimisation.

Return type:

List[float]

get_predicted_foliation(axial_normal: ndarray) ndarray[source]

Get the predicted foliation.

Parameters:

axial_normal (np.ndarray) – The axial foliation normal vector.

Returns:

Returns the normal vectors to the predicted foliation.

Return type:

np.ndarray

initialise_model() None[source]

Initialises the geological model and scales the points (xyz).

The GeologicalModel class is initialised with the bounding box. The xyz points of the FoldModel object are then scaled using the geological model.

Return type:

None

process_axial_surface_proposition(axial_normal: ndarray) DataFrame[source]

Process the axial surface proposition at each iteration by creating a dataset from the axial surface normal.

The axial surface normal is first normalised. A dataset is then created from the axial surface normal. A rotated vector is created by rotating the axial normal by 90 degrees to be perpendicular to the axial surface. The rotated vector is the Y axis of the fold frame.

Parameters:

axial_normal (np.ndarray) – The axial surface normal vector.

Returns:

The dataset to use to build a fold frame.

Return type:

pd.DataFrame

FoldOptLib.fold_modelling.engine.fold_function(params)[source]

FoldOptLib.fold_modelling.simple_fold_frame_builder module

Module contents