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.

Tensor size error

See original GitHub issue

Hi! I have a problem while loading the model with faceapi.nets.faceLandmark68Net.loadFromUri('/public/models')

The model is available at the models directory. But an error arises while loading the model selected. In this case face_landmark_68_model-shard1 and face_landmark_68_model-weights-manifest.json are placed into the directory. But the following error appears:

Error: Based on the provided shape, [3,3,32,1], the tensor should have 288 values but has 64

Can someone help me please?

EDIT: This error appears if I my loading function is not async, if I make it async another error appears (regeneratorRuntime is not defined)

Thanks for your info

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:1
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
avalanche1commented, Sep 17, 2019

I managed to solve it serving model files from a cdn Use https://gitcdn.xyz/repo/justadudewhohacks/face-api.js/master/weights/ as MODEL_URL

Read more comments on GitHub >

github_iconTop Results From Across the Web

I am getting an Error: "The size of tensor a (10) must match the ...
It is almost always you will need the dimension when you use softmax function: x = F.softmax(x,dim=1) # or whatever dimension you choose....
Read more >
Runtime Error, Tensor size problem · Issue #997 - GitHub
Bug To Reproduce I installed according to install.md, but when I try to train e2e_faster _rcnn, I encounterd following problem: RuntimeError: The size...
Read more >
I got error for dimension of tensor - PyTorch Forums
labels seems to be a scalar and thus doesn't have dimensions: labels = torch.tensor(1.) print(labels.shape) > torch.Size([]) labels.size(0) ...
Read more >
A Static Analyzer for Detecting Tensor Shape Errors in Deep ...
ABSTRACT. We present an automatic static analyzer PyTea that detects tensor- shape errors in PyTorch code. The tensor-shape error is ...
Read more >
How to solve the error: The size of tensor a (16) must match ...
Seems that the tensor output is a resized and the shape of it is not matching with your sharp_image tensor. I would look...
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