question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Need help authoring Model configuration for Pytorch MNIST

See original GitHub issue

Hi I am trying to host my first model in triton.

When I to run inference I get error saying mnist model failed, bad request.

platform: "pytorch_libtorch"
max_batch_size: 0
input [
  {
    name: "INPUT__0"
    data_type: TYPE_FP32
    dims: [ 28,28 ]
  }
]
output [
  {
    name: "output__0"
    data_type: TYPE_FP32
    dims: [ 10 ]
  }
]

What am I missing?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
CoderHamcommented, Nov 10, 2021

@rduser for the image client case it appears the model does not have the inputs format specified in the model config.

Exception: unexpected input format FORMAT_NONE, expecting FORMAT_NCHW or FORMAT_NHWC

This needs to be specified to use the image client as is.

For the second error the number of elements is 783 but it should be 28281 = 784. This is why the HTTP server responds with the shape error.

Please make the necessary fix and try again.

1reaction
CoderHamcommented, Nov 9, 2021

I tried following config but get error saying mnist model failed

Can you share the exact error you are seeing?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Need help authoring Model configuration for Pytorch MNIST
Hi I am trying to host my first model in triton. I ran the MNIST model from examples/main.py at master · pytorch/examples (github.com)...
Read more >
PyTorch MNIST Tutorial - Determined AI Documentation
This tutorial describes how to port an existing PyTorch model to Determined. We will port a simple image classification model for the MNIST...
Read more >
What is torch.nn really? - PyTorch
PyTorch provides the elegantly designed modules and classes torch.nn , torch.optim , Dataset , and DataLoader to help you create and train neural...
Read more >
Introduction to Pytorch Lightning - Read the Docs
This notebook requires some packages besides pytorch-lightning. ... Init our model mnist_model = MNISTModel() # Init DataLoader from MNIST ...
Read more >
Introduction to PyTorch: Build a Neural Network to Recognize ...
Given an image of a handwritten digit, your model w… ... Up a Local Programming Environment for Python 3 to configure everything you...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found