Skip to content

Object Creation API🍋

create_drillholes(name, collar, assays, survey=None, method=DesurveyingMethod.TANGENTIAL, dip_convention=DipDownward.NEGATIVE, name_dictionary={}) 🍋

Create GeoLime drillholes from Collar, Survey and Assay files.

Parameters:

Name Type Description Default
name str

name of Drillholes object to create.

required
collar pd.DataFrame

DataFrame of collar file.

required
assays Union[List[pd.DataFrame], pd.DataFrame]

DataFrame(s) of intervals file (assay, geology, lithology, etc...).

required
survey Optional[pd.DataFrame]

DataFrame of survey file.

None
method DesurveyingMethod

Desurveying method.

DesurveyingMethod.TANGENTIAL
dip_convention DipDownward

Convention of dip downward angle sign.

DipDownward.NEGATIVE
name_dictionary Dict[str, str]

mapping between column names and attributes. See Project().attributes_mapping for default attributes mapping.

{}

Returns:

Type Description
Drillholes

GeoLime Drillholes.

Raises:

Type Description
NotImplementedError

Desurveying method not in the available methods.

create_drillholes_from_dataframe(name, df, name_dictionary={}) 🍋

Warning

This function is deprecated as of GeoLime 1.2 and will be removed in GeoLime 1.4. Use drillholes_from_dataframe instead.

Create Drillholes from a Pandas DataFrame.

Parameters:

Name Type Description Default
name str

Name of created Drillholes.

required
df pd.DataFrame

Ready to conversion DataFrame.

required
name_dictionary Dict[str, str]

Correspondence table mapping names to attributes.

{}

Returns:

Type Description
Drillholes

Drillholes

drillholes_from_dataframe(name, df, name_dictionary={}) 🍋

Create Drillholes from a Pandas DataFrame.

Parameters:

Name Type Description Default
name str

Name of created Drillholes.

required
df pd.DataFrame

Ready to conversion DataFrame.

required
name_dictionary Dict[str, str]

Correspondence table mapping names to attributes.

{}

Returns:

Type Description
Drillholes

Drillholes

point_cloud_from_file(name, file_path, required_columns=[Coord.X, Coord.Y, Coord.Z]) 🍋

Load data from a CSV file and create a PointCloud object.

Parameters:

Name Type Description Default
name str

Name of the PointCloud object.

required
file_path str

Path to the input CSV file.

required
required_columns List[Union[Coord, str]]

List of required column names being the X, Y, and Z coordinate columns.

[Coord.X, Coord.Y, Coord.Z]

Returns:

Type Description
PointCloud

A PointCloud object containing the input data and any additional properties.

Raises:

Type Description
ValueError
  • Input file format is not CSV.
  • Required columns are missing or contain invalid data.

create_gis_object_from_file(name, file_path) 🍋

Warning

This function is deprecated as of GeoLime 1.2 and will be removed in GeoLime 1.4. Use gis_object_from_file instead.

Create GeoLime GIS object from a shp, geojson or gpkg file.

The file loading is delegated to GeoPandas: see GeoPandas - Read for more information.

Parameters:

Name Type Description Default
name str

name of the GISObject to create.

required
file_path str

path to the shp, geojson or gpkg file.

required

Returns:

Type Description
GISObject

GeoLime GISObject.

gis_object_from_file(name, file_path) 🍋

Create GeoLime GIS object from a shp, geojson or gpkg file. The file loading is delegated to GeoPandas: see GeoPandas - Read for more information.

Parameters:

Name Type Description Default
name str

name of the GISObject to create.

required
file_path str

path to the shp, geojson or gpkg file.

required

Returns:

Type Description
GISObject

GeoLime GISObject.

block_model_from_file(name, file_path, required_columns=[Coord.X, Coord.Y, Coord.Z]) 🍋

Load data from a CSV file and create a BlockModel object.

Parameters:

Name Type Description Default
name str

Name of the BlockModel object.

required
file_path str

Path to the input CSV file.

required
required_columns List[Union[Coord, str]]

List of required column names being the X, Y, and Z coordinate columns.

[Coord.X, Coord.Y, Coord.Z]

Returns:

Type Description
BlockModel

A BlockModel object containing the input data and any additional properties.

Raises:

Type Description
ValueError
  • Input file format is not CSV.
  • Required columns are missing or contain invalid data.