Skip to content

Commit

Permalink
added onnx model conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiocarrara committed Feb 3, 2022
1 parent f9c3b15 commit c8dc801
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ FROM tensorflow/tensorflow:2.4.1-gpu-jupyter
RUN apt update && apt install -y nvidia-modprobe
RUN pip install adabelief-tf pandas imageio imageio-ffmpeg seaborn sklearn tensorflow_addons tqdm
RUN pip install keras_applications tensorflowjs

RUN pip install tf2onnx
8 changes: 8 additions & 0 deletions convert_to_onnx.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#/bin/bash

# prerequisite:
# pip install tf2onnx

RUNDIR="path/to/run/dir"

python -m tf2onnx.convert --saved-model $RUNDIR/best_savedmodel --output $RUNDIR/best_model.onnx

0 comments on commit c8dc801

Please sign in to comment.