This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Error example: | |
# ERROR: for redis cannot stop container: 16028f9: | |
# Cannot kill container 16028f9: unknown error after kill: docker-runc did not terminate sucessfully: | |
# container_linux.go:393: signaling init process caused "permission denied" | |
# | |
# This error was caused by AppArmor service in Ubuntu | |
# It was not working normally due to some unknown issues. | |
# Run following commands to fix it. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import json | |
url="YOUR_PREDICTION_ENDPOINT _ AVAIL customvision.ai" | |
headers={'content-type':'application/octet-stream','Prediction-Key':'YOUR_PREDICTION_KEY'} | |
r =requests.post(url,data=open("YOUR_LOCAL_IMAGE.jpg","rb"),headers=headers) | |
print(r.content) |