Releases: DigitalGrainSize/SediNet
Releases · DigitalGrainSize/SediNet
v1.3
Major change to code and options. Also marks a version used to re-analyze SandSnap imagery
- fixed generator error by adding exception and print statement to
get_data_generator_Nvars_siso_simo
,get_data_generator_Nvars_miso_mimo
, andget_data_generator_1image
- new optimised
defaults.py
values (image size = 768, batch_size = 4, shallow=True) - added
BASE_CAT
andBASE_CONT
options todefaults.py
- added image size, model depth, to output file names
- added
CAT_DENSE_UNITS
andCONT_DENSE_UNITS
options todefaults.py
- added
CONT_LOSS
andCAT_LOSS
options todefaults.py
, with defaults fromtensorflow_addons
(conda env yml updated). loss for categorical models can now befocal
(default) orcategorical_crossentropy
. Models for continuous variables can now bepinball
(default) - all global variables are now capitalized, for readability/etc
- general tidy up of code for readability
- fixed bug in categorical model training (expected ndarray, not list, for batch labels)
- fixed bug in categorical model plotting
- added LICENSE
- now can take multiple batch sizes and build an ensemble model. This generally results in higher accuracy but more models = more model training time
- response variables can be scaled using a robust scaler, or not. Use
scale=True
in a config file to use scaling - now checks for estimating weights path in root and
res_folder
directory and, if present, uses it. This can be used to add batch size combinations sequentially - optionally, training imagery is now augmented if
DO_AUG=True
(in the defaults file). This doubles the training set, by augmenting each image (random horizontal shift, followed by a vertical flip) - file names shorter (number of variables enumerated rather than each listed)
- improved/rewritten README
- more consistent and descriptive filenaming convention
- simpler structure:
train
only does training (no prediction). Usepredict
to get train and test sets evaluation. This also allows defaulting to CPU for prediction, to avoid OOM errors that are more likely using GPU for prediction - no separate config file for prediction. One config file for both training and prediction
- fixed many bugs, including one that was using 3-band greyscale imagery (doh!)
- uses an exponentially decreasing learning rate scheduler rather than adaptive (because validation loss can be erratic)
- uses depthwise separable 2d convolutions rather than trad 2d convs. see here
- variables in
defaults.py
based on consideration of accuracy across many datasets, both included and not included as pat of the SediNet package - categorical models also have a shallow and false option
predict_all.sh
is a fully worked example of using the framework to predict on all continuous datasets- simplified yml conda env, and a requirements.txt
- added
sedinet_predict1image.py
for making predictions on a single image - added
sedinet_predictfolder.py
for making predictions on a folder of images
The most important changes area
- depthwise separable convolution layers
- exponentially decreasing learning rate scheduler
- pinball loss for continuous variables
- focal loss and "shallow=False" for categorical variables
- training and prediction using model ensembles trained with up to 4 different batch sizes
v1.0 initial submission of SediNet paper to journal
Update README.md