Closed alexdesiqueira closed 3 years ago
Hey @stefanv,
Question: is there graceful fallback when the NN model file is not found?
It downloads the files automatically:
❯ ./pipeline.py -u
(...)
Image 1/1 : BMNHE_500607.JPG
models/segmentation.pkl not in the path. Downloading...
Downloading data from 'https://gitlab.com/mothra/mothra-data/-/raw/main/models/segmentation/segmentation.pkl' to file '/home/alex/projects/mothra/models/segmentation.pkl'.
(...)
Identifying gender...
models/id_gender.pkl not in the path. Downloading...
Downloading data from 'https://gitlab.com/mothra/mothra-data/-/raw/main/models/id_gender/id_gender.pkl' to file '/home/alex/projects/mothra/models/id_gender.pkl'.
You're right, though; I hard-coded where the files should be. I think it'd be nice to have the option to pass the weights, and only then offer to download them.
I think that's fine for now.
Thank you @stefanv!
In this PR, we remove ~classical~classic (Otsu threshold) and grabcut segmentation options, leaving only U-nets.