-
Notifications
You must be signed in to change notification settings - Fork 7
SafeImage Web Service
Daniel Bicho edited this page Jun 7, 2017
·
1 revision
Repository: https://github.com/arquivo/SafeImage/
SafeImage is an Web Service, where the users can submit an image and obtain the NSFW (Not Safe for Work) score of the image.
SafeImage is composed by two components:
- An REST WebService API provided by Flask Framework.
- A Deep Neural Network to classify images using Tensorflow.
Currently reported performance evaluation on Arquivo.pt Image Search queries:
git clone https://github.com/arquivo/SafeImage.git
- An working enviroment with Python2.7.
- Install Requirements.txt with pip.
cd SafeImage/
pip install -r requirements.txt
- Install SafeImage API:
python setup.py install
uwsgi uwsgi.ini
python client_test.py http://example.org/image.jpg
Request a POST to /safeimage path with the following JSON content:
POST /safeimage
{
"image": image_64
}
Replace 'image_64' with the base64 encoded image bytes.