Retrieving and analysing BHR-GT grainsize samples#

In this example, we will download BHR-GT geotechnical boreholes (BRO BHR-GT objects) and associated grainsize sample data.

ℹ️ This example is work-in-progress. Additional features developed for working with grainsize data will follow in future versions of GeoST.

You must download the BHR-GT borehole data (i.e. layer descriptions) and grainsize sample data seperately. In this example we will only download grainsize sample data using a bounding box in WGS84 UTM 31N coordinates (EPSG:32631) that roughly covers the offshore sand mining area L12-2 in the Dutch North Sea.

import geost

# Corresponding samples, using the object type 'BHR-GT-samples'
bhrgt_samples = geost.bro_api_read(
    "BHR-GT-samples", bbox=(619_000, 5_924_000, 625_000, 5_930_000), epsg=32631
)

# Show results of downloaded samples
print("\nThe data tables look like this:")
print(bhrgt_samples.data.head())
The data tables look like this:
                nr              x             y  surface    end   top  bottom  \
0  BHR000000451643  622448.566157  5.927032e+06   -27.13 -32.08  0.20    0.40   
1  BHR000000451643  622448.566157  5.927032e+06   -27.13 -32.08  0.65    0.85   
2  BHR000000451643  622448.566157  5.927032e+06   -27.13 -32.08  1.60    1.80   
3  BHR000000451643  622448.566157  5.927032e+06   -27.13 -32.08  2.20    2.40   
4  BHR000000451643  622448.566157  5.927032e+06   -27.13 -32.08  3.20    3.40   

   fractionSmaller63um  fractionLarger63um  fraction63to90um  ...  \
0                  0.0               100.0               0.2  ...   
1                  2.2                97.8               2.6  ...   
2                  1.7                98.3               1.8  ...   
3                  1.9                98.1               2.1  ...   
4                  1.0                99.0               0.4  ...   

   fraction500to710um  fraction710to1000um  fraction1000to1400um  \
0                 0.8                  0.3                   0.2   
1                 0.1                  0.1                   0.0   
2                 0.3                  0.1                   0.0   
3                 0.4                  0.1                   0.0   
4                49.4                 17.0                   3.0   

   fraction1400umto2mm  fraction2to4mm  fraction4to8mm  fraction8to16mm  \
0                  0.2             1.2             0.0              0.0   
1                  0.1             0.2             0.0              0.0   
2                  0.0             0.0             0.0              0.0   
3                  0.0             0.0             0.0              0.0   
4                  0.7             2.7             0.0              0.0   

   fraction16to31_5mm  fraction31_5to63mm  fractionLarger63mm  
0                 0.0                 0.0                 0.0  
1                 0.0                 0.0                 0.0  
2                 0.0                 0.0                 0.0  
3                 0.0                 0.0                 0.0  
4                 0.0                 0.0                 0.0  

[5 rows x 25 columns]

Currently there are two analysis functions available for BHR-GT grainsize sample data: calculate_bhrgt_grainsize_percentiles and calculate_bhrgt_grainsize_fractions. Let’s apply both to get some commonly used grain size metrics:

from geost.analysis.grainsize import (
    calculate_bhrgt_grainsize_fractions,
    calculate_bhrgt_grainsize_percentiles,
)

# Calculate grain size percentiles and fractions for the downloaded samples
bhrgt_samples = calculate_bhrgt_grainsize_percentiles(
    bhrgt_samples, percentiles=[10, 50, 90], only_sand=True
)
bhrgt_samples = calculate_bhrgt_grainsize_fractions(bhrgt_samples)

# Show results
print("\nThe data tables look like this:")
print(
    bhrgt_samples.data[
        [
            "nr",
            "top",
            "bottom",
            "d10_sand",
            "d50_sand",
            "d90_sand",
            "perc_fines",
            "perc_sand",
            "perc_gravel",
        ]
    ].head()
)
The data tables look like this:
                nr   top  bottom    d10_sand    d50_sand    d90_sand  \
0  BHR000000451643  0.20    0.40  155.955128  232.863741  348.912052   
1  BHR000000451643  0.65    0.85  115.571429  155.895062  221.608939   
2  BHR000000451643  1.60    1.80  126.652709  162.163383  230.549815   
3  BHR000000451643  2.20    2.40  117.535714  155.003671  216.043478   
4  BHR000000451643  3.20    3.40  170.297753  593.309717  898.841176   

   perc_fines  perc_sand  perc_gravel  
0         0.0       98.8          1.2  
1         2.2       97.6          0.2  
2         1.7       98.3          0.0  
3         1.9       98.1          0.0  
4         1.0       96.3          2.7