nikos-glikis / nsfw-docker Goto Github PK
View Code? Open in Web Editor NEWYahoo OpenNSFW Docker
Yahoo OpenNSFW Docker
Brand new install of Ubuntu 17.10 in a virtual machine (also tested on a laptop), I go through the installation instructions, everything seems fine and when I try to run it I get this:
libdc1394 error: Failed to initialize libdc1394
WARNING: Logging before InitGoogleLogging() is written to STDERR
F0308 20:22:54.235227 1 blob.hpp:122] Check failed: axis_index < num_axes() (1 vs. 1) axis 1 out of range for 1-D Blob with shape 2 (2)
*** Check failure stack trace: ***
Any ideas?
----------------------------------------
172.17.0.1 - - [11/Sep/2018 19:39:25] "GET /https://blog.rakutenmarketing.com/wp-content/uploads/2018/08/Holiday-Shopper_Feature-Image.png HTTP/1.1" 200 -
https://blog.rakutenmarketing.com/wp-content/uploads/2018/08/Holiday-Shopper_Feature-Image.png
ERROR:root:ok
Traceback (most recent call last):
File "server.py", line 19, in do_GET
message = classify_nsfw.get_score(self.path[1:])
File "/workspace/classify_nsfw.py", line 128, in get_score
with c.request('GET', url, preload_content=False) as resp, open(tmp_filename, 'wb') as out_file:
File "/usr/lib/python2.7/dist-packages/urllib3/request.py", line 75, in request
**urlopen_kw)
File "/usr/lib/python2.7/dist-packages/urllib3/request.py", line 88, in request_encode_url
return self.urlopen(method, url, **urlopen_kw)
File "/usr/lib/python2.7/dist-packages/urllib3/poolmanager.py", line 155, in urlopen
response = conn.urlopen(method, u.request_uri, **kw)
File "/usr/lib/python2.7/dist-packages/urllib3/connectionpool.py", line 599, in urlopen
raise SSLError(e)
SSLError: hostname 'blog.rakutenmarketing.com' doesn't match 'blog.marketing.rakuten.co.uk'
----------------------------------------
Exception happened during processing of request from ('172.17.0.1', 38900)
Traceback (most recent call last):
File "/usr/lib/python2.7/SocketServer.py", line 295, in _handle_request_noblock
self.process_request(request, client_address)
File "/usr/lib/python2.7/SocketServer.py", line 321, in process_request
self.finish_request(request, client_address)
File "/usr/lib/python2.7/SocketServer.py", line 334, in finish_request
self.RequestHandlerClass(request, client_address, self)
File "/usr/lib/python2.7/SocketServer.py", line 649, in __init__
self.handle()
File "/usr/lib/python2.7/BaseHTTPServer.py", line 340, in handle
self.handle_one_request()
File "/usr/lib/python2.7/BaseHTTPServer.py", line 328, in handle_one_request
method()
File "server.py", line 22, in do_GET
message = "exception: " + e.message
TypeError: cannot concatenate 'str' and 'CertificateError' objects
If I pass in any image from blog.rakutenmarketing.com, I get this error. My preferred outcome would be to ignore the SSL error altogether, like browsers seem to. However, regardless of that, there's the concatenation error on line 22.
Is there a way to lower the logging level on this docker image?
I've tried setting the logging level in the python script but get an error stating it doesn't know the os.environ variable. Sorry, I'm not terribly familiar with python.
os.environ['GLOG_minloglevel'] = '2'
As per http://stackoverflow.com/questions/29788075/setting-glog-minloglevel-1-to-prevent-output-in-shell-from-caffe
The logging causes the docker image on my Mac to enlarge to 50+GB in just a few hours of processing images and I really don't need any of the debugging level information (or anything really at all as I know all my images either work or don't).
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
load image file is string is not covert to bytes how to solve it
classify_nsfw.py file is not run witout docker.....am try to run cpu only method but this code compile error UTF-8 unicode error apears they cant convert string to bytes
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.