You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please refer to [WIKI](https://github.com/cap-ntu/ML-Model-CI/wiki) for more CLIs.
159
+
Please refer to [WIKI](https://github.com/cap-ntu/ML-Model-CI/wiki) for more CLI options.
106
160
107
-
### 2. Python Package
161
+
### 2. Running Programmatically
108
162
109
163
```python
110
164
# utilize the convert function
111
-
from modelci.hub.converter importONNXConverter
165
+
from modelci.hub.converter importconvert
112
166
from modelci.types.bo import IOShape
113
167
114
168
# the system can trigger the function automaticlly
115
169
# users can call the function individually
116
-
ONNXConverter.from_torch_module(
117
-
'<path to torch model>',
118
-
'<path to export onnx model>',
119
-
inputs=[IOShape([-1, 3, 224, 224], float)],
120
-
)
170
+
convert(
171
+
'<torch model>',
172
+
src_framework='pytorch',
173
+
dst_framework='onnx',
174
+
save_path='<path to export onnx model>',
175
+
inputs=[IOShape([-1, 3, 224, 224], dtype=float)],
176
+
outputs=[IOShape([-1, 1000], dtype=float)],
177
+
opset=11)
121
178
```
122
179
180
+
### 3. Web Interface
181
+
182
+
If you have installed MLModelCI via pip, you should start the frontend service manually.
183
+
184
+
```bash
185
+
# Navigate to the frontend folder
186
+
cd frontend
187
+
# Install dependencies
188
+
yarn install
189
+
# Start the frontend
190
+
yarn start
191
+
```
192
+
193
+
The frontend will start on <http://localhost:3333>
194
+
123
195
## Quickstart with Notebook
124
196
125
197
-[Publish an image classification model](./example/notebook/image_classification_model_deployment.ipynb)[](https://nbviewer.jupyter.org/github/cap-ntu/ML-Model-CI/blob/master/example/notebook/image_classification_model_deployment.ipynb)
0 commit comments