parq_blockmodel.utils.demo_block_model.create_demo_blockmodel
- parq_blockmodel.utils.demo_block_model.create_demo_blockmodel(shape=(3, 3, 3), block_size=(1.0, 1.0, 1.0), corner=(0.0, 0.0, 0.0), azimuth=0.0, dip=0.0, plunge=0.0, parquet_filepath=None)[source]
Create a demo blockmodel DataFrame or Parquet file.
The model contains block coordinates, indices, and depth information.
c_index: A zero based index in C-style order (row-major). The order returned when sorting by x, y, z.
f_index: A zero based index in Fortran-style order (column-major). The order returned when sorting by z, y, x.
depth: The depth of each block, calculated as the distance from the surface (maximum z coordinate).
- Parameters:
shape (
tuple
[int
,int
,int
]) – Shape of the block model (nx, ny, nz).block_size (
tuple
[float
,float
,float
]) – Size of each block (dx, dy, dz).corner (
tuple
[float
,float
,float
]) – The lower left (minimum) corner of the block model.azimuth (
float
) – Azimuth angle in degrees.dip (
float
) – Dip angle in degrees.plunge (
float
) – Plunge angle in degrees.parquet_filepath (
Path
) – If provided, save the DataFrame to this Parquet file and return the file path.
- Return type:
DataFrame
|Path
- Returns:
pd.DataFrame if parquet_filepath is None, else Path to the Parquet file.