onnx Questions

3

I would like to know what are the options I have to run an object detection model in the browser, until now I have found the next options: Streamlit: is very simple but requires the server resourc...
Motion asked 20/8, 2021 at 6:32

5

How to get dimensions of output layers in onnx neural net? I can get onnx graph, but there is no output dimensions: ~/onnx-tensorrt/third_party/onnx/onnx/tools/net_drawer.py --input ./weights/tin...
Gaynor asked 21/8, 2019 at 9:56

2

Solved

Goal: Amend this Notebook to work with albert-base-v2 model Error occurs in Section 1.3. Kernel: conda_pytorch_p36. I did Restart & Run All, and refreshed file view in working directory. There...

4

I've exported my model to ONNX via: # Export the model torch_out = torch.onnx._export(learn.model, # model being run x, # model input (or a tuple for multiple inputs) EXPORT_PATH + "mnist.onnx",...
Exclusion asked 7/11, 2018 at 0:42

2

I have two CoreML models. One works fine, and the other generates this error message: [espresso] [Espresso::ANERuntimeEngine::__forward_segment 0] evaluate[RealTime]WithModel returned 0; code=5 er...
Pesek asked 19/2, 2019 at 18:56

2

Solved

I am trying to convert detr model to tensor flow using onnx. I converted the model using torch.onnx.export with opset_version=12.(which produces a detr.onnx file) Then I tried to convert the onnx f...
Camala asked 5/1, 2023 at 9:16

2

Solved

I am trying to convert the Pegasus newsroom in HuggingFace's transformers model to the ONNX format. I followed this guide published by Huggingface. After installing the prereqs, I ran this code: !r...
Georgeta asked 8/2, 2021 at 20:44

3

Solved

How can I find the input size of an onnx model? I would eventually like to script it from python. With tensorflow I can recover the graph definition, find input candidate nodes from it and then obt...
Ciaracibber asked 24/6, 2019 at 10:25

1

I'm trying to train a model in mixed precision. However, I want a few of the layers to be in full precision for stability reasons. How do I force an individual layer to be float32 when using torch....
Sulphide asked 22/8, 2022 at 18:3

3

Solved

I'm trying to install onnx in a fresh Ubuntu 20.04 install, but I'm running into the error bellow. It seems that I need the protobuf compiler, although I haven't found any documentation that says t...
Kronos asked 25/4, 2020 at 22:20

2

I have been training a model in the Pytorch framework using multiple convolutional layers (3x3, stride 1, padding same). The model performs well and I want to use it in Matlab for inference. For th...
Headforemost asked 28/7, 2021 at 17:46

1

Solved

I can't find anyone who explains to a layman how to load an onnx model into a python script, then use that model to make a prediction when fed an image. All I could find were these lines of code: s...
Rouse asked 26/2, 2022 at 20:13

2

I have exported my PyTorch model to ONNX. Now, is there a way for me to obtain the input layer from that ONNX model? Exporting PyTorch model to ONNX import torch.onnx checkpoint = torch.load("./s...
Nova asked 27/6, 2019 at 17:24

2

I was comparing the inference times for an input using pytorch and onnxruntime and I find that onnxruntime is actually slower on GPU while being significantly faster on CPU I was tryng this on Wind...
Jetta asked 17/1, 2022 at 11:3

1

Solved

Goal: Amend this Notebook to work with albert-base-v2 model. Kernel: conda_pytorch_p36. I did Restart & Run All, and refreshed file view in working directory. In order to evaluate and to expor...

2

Solved

I am learning this new ONNX framework that allows us to deploy the deep learning (and others) model into production. However, there is one thing I am missing. I thought that the main reason for hav...
Greed asked 27/6, 2021 at 15:26

3

I'm trying to run an ONNX model import onnxruntime as ort import onnxruntime.backend model_path = "model.onnx" #https://microsoft.github.io/onnxruntime/ ort_sess = ort.InferenceSession(m...
Fusion asked 20/10, 2020 at 19:23

5

Trying to convert this pytorch model with ONNX gives me this error. I've searched github and this error came up before in version 1.1.0 but was apparently rectified. Now I'm on torch 1.4.0. (python...
Wingard asked 14/3, 2020 at 12:17

2

I am using ML.NET to import an ONNX model to do object detection. For the record, I exported the model from the CustomVision.ai site from Microsoft. I inspected the model file in Netron and it cle...
Tsar asked 30/7, 2019 at 5:31

3

I'm running a Mask R-CNN model on an edge device (with an NVIDIA GTX 1080). I am currently using the Detectron2 Mask R-CNN implementation and I archieve an inference speed of around 5 FPS. To spee...
Mascle asked 18/12, 2019 at 14:49

1

Solved

I have Pytorch model.pth using Detectron2's COCO Object Detection Baselines pretrained model R50-FPN. I am trying to convert the .pth model to onnx. My code is as follows. import io import numpy as...
Tightlipped asked 31/10, 2020 at 15:19

1

Solved

I am writing a python script, which converts any deep learning models from popular frameworks (TensorFlow, Keras, PyTorch) to ONNX format. Currently I have used tf2onnx for tensorflow and keras2onn...
Phaih asked 28/7, 2020 at 9:42

2

I am currently working with Darknet on Yolov4, with 1 class. I need to export those weights to onnx format, for tensorRT inference. I've tried multiple technics, using ultralytics to convert or goi...
Chewink asked 1/7, 2020 at 8:50

1

I have a seq2seq model in PyTorch that I want to run with CoreML. When exporting the model to ONNX the input dimensions are fixed to the shape of the tensor used during export, and again with the c...
Willams asked 17/5, 2020 at 10:27

4

Solved

I have trained a CNN in Matlab 2019b that classifies images between three classes. When this CNN was tested in Matlab it was functioning fine and only took 10-15 seconds to classify an image. I use...
Stockbroker asked 18/4, 2020 at 21:54

© 2022 - 2025 — McMap. All rights reserved.