By: Max Midwinter
CVISS Labs, Dept. CEE, University of Waterloo
Rogers 5G Smart Infrastructure, 2021
Run main.py for sample program
-
Call prepDefect ( ) in main.py
prepDefect takes 4 parameters:- REF_DIR: dir containing the reference frame
- SUB_DIR: dir containing other images of the defect
- AUG_DIR: dir where the preprocessed images are saved
- scale: % to resize the raw images (Depends on your GPU and number of filters)
- Keep resolution below 500x500
-
Call scribbsDefect ( ) in main.py
scribbsDefect takes 2 parameters:- AUG_DIR: dir where images are saved
- scribbs: scribbles to feed in
- usually leave at None
- save: save output image
- For Debug save image (saved in current directory)
pip install docker
# Let me know if this does not work...
docker pull tensorflow/tensorflow:2.4.2-gpu
Build docker image usp with your choice of tag
docker docker build -t usp:TAG .
docker run usp:TAG
If you are running on local computer this command will start a dev server. (i.e. http://172.17.0.2:5000/)
You can now push your docker image to a container registry of your choice and deploy a kubernetes service...
To take advantage of parallel inference... Run main_docker.py (with your API)