mdietrichstein / tensorflow-open_nsfw

Tensorflow Implementation of Yahoo's Open NSFW Model

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Help exporting to saved model

bho01 opened this issue · comments

I am new to tensorflow and I need help exporting this model as a savedmodel to use it in tensorflowJS.

I used this command:

python export_savedmodel.py

and it returns this:

usage: export_savedmodel.py [-h] -i {tensor,base64_jpeg} [-v EXPORT_VERSION]
-m MODEL_WEIGHTS
target
export_savedmodel.py: error: too few arguments

but I have no clue what to fill the arguments with.

I just export model in Windows ,-m is the npy path, -i you should use tensor or base64_jpeg
try this command
python export_savedmodel.py -m D:\PyProject\tensorflow-open_nsfw-master\data\open_nsfw-weights.npy -i tensor D:\tfout
if you use linux ,you can try
python export_savedmodel.py -m ./data/open_nsfw-weights.npy -i tensor ./tfout