Miscellaneous Operations
import geolime as geo
from pyproj import CRS
import numpy as np
GeoLime python library consists in objects suited for geoscience analyses and specifically resource modelling and estimation.
Load rocklea drillholes geolime objects using existing dataset included in the library.
dh = geo.datasets.load(data_name="rocklea_dome/dh_hyper.geo")
Explore Loaded objects¶
dh.name
'rck_hs'
We can list the different holes using the holeids()
method.
dh.holeids()
array(['RKC278', 'RKC279', 'RKC280', 'RKC281', 'RKC282', 'RKC283', 'RKC284', 'RKC285', 'RKC286', 'RKC287', 'RKC288', 'RKC289', 'RKC290', 'RKC291', 'RKC292', 'RKC293', 'RKC294', 'RKC295', 'RKC296', 'RKC297', 'RKC298', 'RKC299', 'RKC300', 'RKC301', 'RKC302', 'RKC303', 'RKC304', 'RKC305', 'RKC306', 'RKC307', 'RKC308', 'RKC309', 'RKC310', 'RKC311', 'RKC312', 'RKC313', 'RKC314', 'RKC315', 'RKC316', 'RKC317', 'RKC318', 'RKC319', 'RKC320', 'RKC321', 'RKC322', 'RKC323', 'RKC324', 'RKC325', 'RKC326', 'RKC327', 'RKC328', 'RKC329', 'RKC330', 'RKC331', 'RKC332', 'RKC333', 'RKC334', 'RKC335', 'RKC336', 'RKC337', 'RKC338', 'RKC339', 'RKC340', 'RKC341', 'RKC342', 'RKC344', 'RKC345', 'RKC346', 'RKC347', 'RKC348', 'RKC358', 'RKC359', 'RKC360', 'RKC361', 'RKC362', 'RKC363', 'RKC364', 'RKC365', 'RKC366', 'RKC367', 'RKC368', 'RKC369', 'RKC370', 'RKC371', 'RKC372', 'RKC373', 'RKC374', 'RKC375', 'RKC376', 'RKC377', 'RKC378', 'RKC379', 'RKC380', 'RKC381', 'RKC382', 'RKC383', 'RKC384', 'RKC385', 'RKC386', 'RKC387', 'RKC388', 'RKC389', 'RKC390', 'RKC391', 'RKC392', 'RKC393', 'RKC394', 'RKC395', 'RKC396', 'RKC397', 'RKC398', 'RKC399', 'RKC400', 'RKC401', 'RKC402', 'RKC403', 'RKC404', 'RKC405', 'RKC406', 'RKC407', 'RKC408', 'RKC409', 'RKC410', 'RKC411', 'RKC412', 'RKC413', 'RKC414', 'RKC415', 'RKC416', 'RKC417', 'RKC418', 'RKC419', 'RKC420', 'RKC421', 'RKC422', 'RKC423', 'RKC424', 'RKC425', 'RKC426', 'RKC427', 'RKC428', 'RKC429', 'RKC430', 'RKC431', 'RKC432', 'RKC433', 'RKC437', 'RKC438', 'RKC443', 'RKC444', 'RKC445', 'RKC446', 'RKC447', 'RKC448', 'RKC449', 'RKC450', 'RKC451', 'RKC452', 'RKC453', 'RKC454', 'RKC455', 'RKC456', 'RKC457', 'RKC458', 'RKC459', 'RKC460', 'RKC461', 'RKC462', 'RKC463', 'RKC464', 'RKC465', 'RKC466', 'RKC467', 'RKC468', 'RKC469', 'RKC470', 'RKC471', 'RKC472', 'RKC473', 'RKC474', 'RKC475', 'RKC476', 'RKC477', 'RKC478', 'RKC479', 'RKC480', 'RKC481', 'RKC482', 'RKC483', 'RKC484', 'RKC485', 'RKD015'], dtype=object)
List all available methods and attribute of an object:
dh
Drillholes └─aggregate() └─bounds() └─builtins ⇨ {'X': 0, 'Y': 1, 'Z': 2, 'HOLEID': 3, 'FROM': 4, 'TO': 5} └─centroid() └─collar_coords() └─convert_to_gis_object() └─coords() └─copy() └─data() └─default_support ⇨ ELEMENT └─delete_composites() └─delete_holes() └─describe() └─element_count() └─generate_attribute_name() └─holeids() └─internals() └─keep_composites() └─keep_holes() └─mid_coords() └─name ⇨ rck_hs └─node_coords() └─plot_2d() └─properties() └─property() └─read_file() └─read_manifest() └─refresh_attributes() └─region() └─region_mask() └─regions() └─remove_attribute() └─remove_property() └─remove_region() └─rename_attribute() └─rename_property() └─rename_region() └─sample_count() └─set_property() └─set_property_expr() └─set_property_value() └─set_region() └─set_region_condition() └─set_region_value() └─to_csv() └─to_dataframe() └─to_file() └─to_pyvista() └─transform() └─translate_by() └─user_properties()
dh.describe()
__TOPO_LEVEL__ | __TOPO_TYPE__ | __TOPO_ELEMENT_V1__ | __TOPO_ELEMENT_V2__ | FROM | TO | X_COLLAR | Y_COLLAR | Z_COLLAR | X_M | ... | LOI | Fe_ox_ai | hem_over_goe | kaolin_abundance | kaolin_composition | wmAlsmai | wmAlsmci | carbai3pfit | carbci3pfit | Depth | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
count | 7134.0 | 7134.0 | 7134.000000 | 7134.000000 | 7134.000000 | 7134.000000 | 7134.000000 | 7.134000e+03 | 7134.000000 | 7134.000000 | ... | 4979.000000 | 6920.000000 | 6663.000000 | 3850.000000 | 3850.000000 | 1693.000000 | 1693.000000 | 343.000000 | 343.000000 | 7134.000000 |
mean | 2.0 | 1.0 | 3662.478133 | 3663.478133 | 20.547939 | 21.547939 | 547414.513625 | 7.475480e+06 | 458.496790 | 547414.513625 | ... | 11.303017 | 0.175605 | 910.741882 | 0.162095 | 1.023877 | 0.053175 | 2207.759327 | 0.070173 | 2319.090816 | 42.666526 |
std | 0.0 | 0.0 | 2118.998485 | 2118.998485 | 13.833730 | 13.833730 | 686.760995 | 1.585644e+03 | 7.466562 | 686.760995 | ... | 4.642987 | 0.083948 | 8.857894 | 0.082429 | 0.046523 | 0.038166 | 3.046365 | 0.024599 | 9.787246 | 11.263359 |
min | 2.0 | 1.0 | 0.000000 | 1.000000 | 0.000000 | 1.000000 | 545494.900000 | 7.472793e+06 | 441.000000 | 545494.900000 | ... | 0.710000 | 0.001300 | 869.780000 | 0.017200 | 0.937000 | 0.020000 | 2186.280000 | 0.040100 | 2296.430000 | 7.000000 |
25% | 2.0 | 1.0 | 1823.250000 | 1824.250000 | 9.000000 | 10.000000 | 546904.700000 | 7.474003e+06 | 453.800000 | 546904.700000 | ... | 9.670000 | 0.107000 | 907.705000 | 0.091025 | 0.991000 | 0.028100 | 2206.370000 | 0.052750 | 2312.235000 | 37.000000 |
50% | 2.0 | 1.0 | 3663.500000 | 3664.500000 | 19.000000 | 20.000000 | 547586.100000 | 7.475604e+06 | 458.200000 | 547586.100000 | ... | 11.200000 | 0.185500 | 911.130000 | 0.161000 | 1.007000 | 0.039600 | 2206.910000 | 0.063600 | 2321.900000 | 46.000000 |
75% | 2.0 | 1.0 | 5499.750000 | 5500.750000 | 31.000000 | 32.000000 | 547947.600000 | 7.476004e+06 | 463.600000 | 547947.600000 | ... | 11.900000 | 0.246000 | 914.480000 | 0.226000 | 1.049750 | 0.064200 | 2208.140000 | 0.080500 | 2324.615000 | 51.000000 |
max | 2.0 | 1.0 | 7324.000000 | 7325.000000 | 60.000000 | 61.000000 | 548498.100000 | 7.479595e+06 | 478.600000 | 548498.100000 | ... | 45.280000 | 0.355000 | 974.080000 | 0.413000 | 1.192000 | 0.285000 | 2233.120000 | 0.182000 | 2338.390000 | 61.000000 |
8 rows × 38 columns
Spatial Information¶
Bounds of an object represent the coordinates of the most furthest points of the bounding box of the object.
dh.bounds()
array([[5.4549490e+05, 7.4727934e+06, 3.8970000e+02], [5.4849810e+05, 7.4795953e+06, 4.7810000e+02]])
Centroid correspond to the mean coordinates of the data along each axis. It can be also be seen as the "center of mass" or barycentre.
dh.centroid()
array([5.47414514e+05, 7.47548047e+06, 4.37448851e+02])
Aggregate value along a drillhole¶
Aggregation operations aims to reduce the number of spatial dimension of a GeoLime object. This will enable to display object on map with a selected property with a specific aggregation method. Drillholes object are aggregated along a specific hole, meaning that all values from a given hole are aggregated using the specific aggregation method. Aggregation methods are available.
Note that the aggregation is not weighted by the composite size, meaning that irregular composite may lead to biased aggregation value.
Get the smallest grade per drillhole¶
dh.aggregate(properties=["Fe"], agg_methods=["min"])
HOLEID | X_min | X | Y_min | Y | Z_min | Z | __TOPO_LEVEL___min | __TOPO_TYPE___min | __TOPO_ELEMENT_V1___min | ... | LOI_min | Fe_ox_ai_min | hem_over_goe_min | kaolin_abundance_min | kaolin_composition_min | wmAlsmai_min | wmAlsmci_min | carbai3pfit_min | carbci3pfit_min | Depth_min | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | RKC278 | 548001.3 | 548001.3 | 7474002.1 | 7474002.1 | 406.5 | 453.5 | 2 | 1 | 0 | ... | 7.30 | 0.01950 | 891.13 | 0.0269 | 0.958 | 0.0210 | 2206.08 | 0.0582 | 2301.30 | 47.0 |
1 | RKC279 | 547804.6 | 547804.6 | 7474004.5 | 7474004.5 | 407.4 | 453.4 | 2 | 1 | 48 | ... | 8.16 | 0.01950 | 893.42 | 0.0243 | 0.974 | 0.0217 | 2205.88 | 0.0450 | 2301.66 | 46.0 |
2 | RKC280 | 547310.8 | 547310.8 | 7474002.2 | 7474002.2 | 403.8 | 453.8 | 2 | 1 | 95 | ... | 8.53 | 0.03920 | 892.49 | 0.0254 | 0.946 | 0.0240 | 2205.81 | 0.0420 | 2323.12 | 51.0 |
3 | RKC281 | 547100.8 | 547100.8 | 7474003.4 | 7474003.4 | 416.4 | 453.4 | 2 | 1 | 146 | ... | 8.27 | 0.03150 | 895.25 | 0.1160 | 0.971 | 0.0222 | 2205.89 | 0.0626 | 2314.86 | 37.0 |
4 | RKC282 | 547199.0 | 547199.0 | 7474801.2 | 7474801.2 | 449.0 | 456.0 | 2 | 1 | 184 | ... | NaN | 0.11500 | 908.45 | 0.1520 | 1.065 | NaN | NaN | NaN | NaN | 7.0 |
... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... |
187 | RKC482 | 547748.8 | 547748.8 | 7475997.8 | 7475997.8 | 410.5 | 465.5 | 2 | 1 | 7125 | ... | 7.42 | 0.05810 | 892.78 | 0.0229 | 0.986 | 0.0215 | 2206.20 | 0.0436 | 2322.69 | 55.0 |
188 | RKC483 | 547825.6 | 547825.6 | 7473716.0 | 7473716.0 | 405.7 | 452.7 | 2 | 1 | 7181 | ... | 5.24 | 0.01510 | 889.28 | 0.0321 | 0.965 | 0.0299 | 2205.54 | 0.0526 | 2310.33 | 47.0 |
189 | RKC484 | 547866.5 | 547866.5 | 7473820.9 | 7473820.9 | 406.4 | 452.4 | 2 | 1 | 7229 | ... | 8.00 | 0.00686 | 884.35 | 0.0353 | 0.976 | 0.0237 | 2205.70 | 0.0479 | 2305.67 | 46.0 |
190 | RKC485 | 547913.3 | 547913.3 | 7473917.2 | 7473917.2 | 407.4 | 452.4 | 2 | 1 | 7276 | ... | 8.75 | 0.03780 | 888.81 | 0.0306 | 0.985 | 0.0219 | 2205.02 | NaN | NaN | 46.0 |
191 | RKD015 | 547905.0 | 547905.0 | 7476800.0 | 7476800.0 | 469.0 | 470.0 | 2 | 1 | 7322 | ... | NaN | NaN | NaN | NaN | NaN | NaN | NaN | NaN | NaN | 41.0 |
192 rows × 45 columns