git clone https://github.com/norahsakal/pycaribbean-2019-shades.git
pip install -r requirements.txt
Use the Jupyter notebook train_your_model.ipynb to train a model
data/
train/
class #/
img001.jpg
img002.jpg
...
class #/
img001.jpg
img002.jpg
...
validation/
class #/
img001.jpg
img002.jpg
...
class #/
img001.jpg
img002.jpg
...
classes = <your classes>
number_of_images_training = <your number of training images>
number_of_images_validation = <your number of validation images>
image_size = (<your size>,<your size>)
model_json = model.to_json()
with open("model.json", "w") as json_file:
json_file.write(model_json)
model.save_weights('your_model.h5')
prediction = loaded_model.predict(img_for_prediction)
classes = {'our_class_name_1': 0, 'our_class_name_2': 1, 'our_class_name_3': 2 ... }
image_size = (<your size>,<your size>)
python app.py
cd /frontend
npm install
npm start