You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.MD
+11-9
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,5 @@
1
+
# Nudity image detection HTTP API
2
+
1
3
This project provides a ready to deploy REST API allowing to predict if an image is offensive or has adult content.
2
4
3
5
It relies on [open_nsfw](https://github.com/yahoo/open_nsfw), which provides a pre-trained open source neural network model for [Caffe](https://github.com/BVLC/caffe).
@@ -74,11 +76,15 @@ and `error_reason` instead of the `score`:
74
76
}
75
77
```
76
78
77
-
##### Batch predictions
78
-
79
79
Remark that doing the classification isn't a fast operation so you shouldn't call this API in places where you want the
80
-
response in real time/low latency (for ex. to display it to the user), but instead call the API periodically. For that
81
-
purpose use the batch classification API as follows.
80
+
response in real time/low latency (for ex. to display it to the user), but instead call the API periodically for a batch
81
+
of images using the endpoint below.
82
+
83
+
#### Batch predictions with streamed responses
84
+
85
+
The batch endpoint takes as input a list of images to classify and returns the result for each image. The response is
86
+
being streamed back, so you could read it in a streaming fashion and process the results as they come in (as opposed
87
+
to wait for the entire response before processing it). For that purpose use the batch classification API as follows.
82
88
83
89
```
84
90
curl -X POST -H 'Content-Type: application/json' \
0 commit comments