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.

Getting "type object argument after ** must be a mapping" error in image generation

See original GitHub issue

Hi, @lucidrains,

We have trained the model using OpenAIs pretrained VAE. We have use the train_dalle.py file for training. python train_dalle.py --image_text_folder=./dataset_images

After training, we have tried to generate the result using the saved model by following command. python generate.py --dalle_path=/content/DALLE-pytorch/dalle-final.pt --text='bird has wings that are brown and has a red crown' --num_images=20

On running the above command we are facing the error: Traceback (most recent call last): File "generate.py", line 55, in <module> vae = DiscreteVAE(**vae_params) TypeError: type object argument after ** must be a mapping, not NoneType

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
pragnakalpdev7commented, Mar 11, 2021

Hello @afiaka87,

We have already tried this trick, but not getting good results. We think maybe we are missing something.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why this unpacking of arguments does not work?
Save this question. Show activity on this post. I get an error type object argument after ** must be a mapping, not tuple...
Read more >
TypeError: DebertaV2ForQuestionAnswering object argument ...
Hi, Iam getting the above type error in my inference code where i input the file ... object argument after ** must be...
Read more >
TypeError: 'x' is not iterable - JavaScript - MDN Web Docs
An iterable can be a built-in iterable type such as Array , String or Map , a generator result, or an object implementing...
Read more >
format() argument after ** must be a mapping, not NoneType
Undercloud or Overcloud Installation Fails with "TypeError: format() argument after ** must be a mapping, not NoneType".
Read more >
MATLAB imresize - Resize image - MathWorks
The axes object contains an object of type image. ... Name-value arguments must appear after other arguments, but the order of the pairs...
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