Visualization
Maplotlib charts
CONFIGS
set_style
set_style (style:dict)
Type | Details | |
---|---|---|
style | dict | Dictionary of plt.rcParams |
EDA
plot_spectra
plot_spectra (X:numpy.ndarray, X_names:numpy.ndarray, figsize=(18, 5), sample=20)
Plot Mid-infrared spectra
Type | Default | Details | |
---|---|---|---|
X | ndarray | Spectra (n_samples, n_wavenumbers) | |
X_names | ndarray | Wavenumbers (n_wavenumbers) | |
figsize | tuple | (18, 5) | Wavenumbers |
sample | int | 20 | Size of random subset |
summary_plot
summary_plot (y:numpy.ndarray, depth_order:numpy.ndarray, tax_lookup:dict)
Type | Details | |
---|---|---|
y | ndarray | Target variable (n_samples) |
depth_order | ndarray | Soil and Depth (n_samples, 2) |
tax_lookup | dict | {‘alfisols’: 0,‘mollisols’: 1, …} |
To see an example of use, see Paper with code / 1. Exploratory Data Analysis
Validation curves
plot_validation_curve
plot_validation_curve (x, losses, ax=None, plot_kwargs={}, fill_between_kwargs={})
Learning curves
plot_learning_curve
plot_learning_curve (x, losses_train, losses_valid, ax=None, train_kwargs={}, valid_kwargs={})
plot_capacity
plot_capacity (x, capacity, ax=None, **kwargs)