weac.parser.plotting.force_penetration_layers module¶
Shared four-panel penetration-resistance / density / layer plots.
- class weac.parser.plotting.force_penetration_layers.ForcePenetrationProfile(*args, **kwargs)[source]¶
Bases:
ProtocolProfile from SMP or SnowScope (resistance–depth signal plus derived density).
- depth_mm: ndarray¶
- penetration_resistance_kPa: ndarray¶
- density_kg_m3: ndarray¶
- density_method: str¶
- __init__(*args, **kwargs)¶
- weac.parser.plotting.force_penetration_layers.plot_force_penetration_layers(profile, layers, *, slope_angle_deg=0.0, depth_axis='plumb', title=None, layer_label='layers', save_path=None, show=True, figsize=(13.0, 6.5))[source]¶
Plot penetration resistance, density, slope-normal density, and layers on a depth axis.
- Parameters:
profile (ForcePenetrationProfile) –
SMPProfileorSnowScopeProfile(must exposedepth_mm,penetration_resistance_kPa,density_kg_m3,density_method).layers (list[Layer]) – WEAC layers ordered surface -> ground (from
extract_layers).Layer.his slope-normal, so the reconstructed staircase is drawn on the slope-normal axis (panels 3-4). For a plumb profile, pass the sameslope_angle_degused to extract the layers so the slope-normal density panel and the staircase share one axis. The staircase bottom overshoots the last sample by one cell because the binning helpers repeat the final sample spacing (an intentional part of their cell model, seelayer_binning).slope_angle_deg (float) – Slope angle [deg] for a plumb profile; sets the
cos(phi)compression of the slope-normal depth axis. Ignored whendepth_axisis"slope-normal"(must stay0).depth_axis (Literal['plumb', 'slope-normal']) –
"plumb"(SnowScope) compresses panels 3-4 bycos(phi)."slope-normal"(SMP) uses the recorded depth as the slope-normal axis with no further scaling.title (str | None) – Figure suptitle; defaults to the density method name.
layer_label (str) – Legend/title label for the segmented panel.
save_path (str | Path | None) – If given, save the figure (PNG) to this path.
show (bool) – Call
plt.show()before returning (defaultTrue).figsize (tuple[float, float]) – Figure size in inches.
- Returns:
The created
Figure.- Return type:
Figure