Skip to content

Commit

Permalink
Add web interface and update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
VanDavv committed Sep 21, 2021
1 parent daac45b commit 1dc4c87
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cli/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

setup(
name='blobconverter',
version='1.1.0',
version='1.1.1',
description='The tool that allows you to covert neural networks to MyriadX blob',
long_description=io.open("README.md", encoding="utf-8").read(),
long_description_content_type="text/markdown",
Expand Down
10 changes: 9 additions & 1 deletion websrc/src/components/ConversionForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ const resolveSteps = source => {
return [model_downloader_step, model_optimizer_step, myriad_compile_step]
case "caffe":
case "tf":
case "onnx":
return [model_optimizer_step, myriad_compile_step]
case "openvino":
return [myriad_compile_step]
Expand Down Expand Up @@ -104,6 +105,13 @@ const ConversionForm = ({modelSource, prevStep, availableZooModels, convertModel
<input id="tf-model" name="tf-model" type="file" accept=".pb" required/>
</div>
}
{
modelSource === "onnx" &&
<div className="form-group">
<label htmlFor="onnx-model">Model file (.onnx)</label>
<input id="onnx-model" name="onnx-model" type="file" accept=".onnx" required/>
</div>
}
{
modelSource === "zoo" &&
<div className="form-group">
Expand Down Expand Up @@ -157,7 +165,7 @@ const ConversionForm = ({modelSource, prevStep, availableZooModels, convertModel
<div className="upper-border">Advanced options</div>
<div className="advanced-options">
{
_.includes(["tf", "caffe"], modelSource) &&
_.includes(["onnx", "tf", "caffe"], modelSource) &&
<div className="advanced-option">
<label htmlFor="advanced-option-input-optimizer"><span>Model optimizer</span> params:</label>
<input type="text" id="advanced-option-input-optimizer" name="advanced-option-input-optimizer" defaultValue={model_optimizer_step['cli_params']}/>
Expand Down
1 change: 1 addition & 0 deletions websrc/src/components/TypeChooser.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ const openVinoVersions = [
const modelSources = [
{label: "Caffe Model", value: "caffe"},
{label: "TensorFlow Model", value: "tf"},
{label: "ONNX Model", value: "onnx"},
{label: "OpenVino Model", value: "openvino"},
{label: "OpenVino Zoo Model", value: "zoo"},
{label: "Config file", value: "file"},
Expand Down
5 changes: 5 additions & 0 deletions websrc/src/redux/sagas/dashboardSaga.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ function* convertModel({payload}) {
optimizer_additional = ` --input_model=$dl_dir/${precision}/${payload['tf-model'].name}`
break;
}
case 'onnx': {
framework = "onnx";
optimizer_additional = ` --input_model=$dl_dir/${precision}/${payload['onnx-model'].name}`
break;
}
}
const filenames = Object.values(payload).map(item => item.name).filter(item => !!item)
const yml = generateYaml({
Expand Down

0 comments on commit 1dc4c87

Please sign in to comment.