1.0 KiB
1.0 KiB
Caffe Converter for Onnx
Target
Convert an Caffe model into Onnx.
Installation
We recommand using docker kneron/intel-caffe to get the full workable environment and the converter itself.
Prerequisites
- Python 3. Python 3.5 is recommanded. You can use Anaconda to create the virtual environment.
For example, run
conda create -n kmc python=3.5and then runconda activate kmc. - onnx. Recommand installing with
pip install onnx. - caffe. intel/caffe is recommended.
Basic Usage
- Go under the
onnx-caffefolder which holds thegenerate_onnx.py. - Try
python generated_onnx.py -hto check the environment. - Run
python generated_onnx.py -o outputfile.onnx -n inputfile.prototxt -w inputfile.caffemodelto convert the model, where-ospecify the output file name and the last parameter is the input file name.
Developer
This project is very similar to keras-onnx. You can check the development guide in this project to get some useful information.