Comments (6)
你好, I used the following versions for testing: python==3.9.1 torch==1.10.0+cu113 torchvision==0.11.1+cu113 tensorboard==2.7.0 numpy==1.21.1 pyyaml==5.4.1 Pillow==8.3.1
from deepfillv2-pytorch.
@nipponjo 好的,谢谢
from deepfillv2-pytorch.
@nipponjo Traceback (most recent call last):
File "/app/deepfillv2-pytorch-master/test.py", line 80, in
main()
File "/app/deepfillv2-pytorch-master/test.py", line 36, in main
generator.load_state_dict(generator_state_dict)
File "/opt/conda/envs/deepfill/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1482, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for Generator:
Missing key(s) in state_dict: "stage1.conv1.conv.weight", "stage1.conv1.conv.bias", "stage1.down_block1.conv1_downsample.conv.weight", "stage1.down_block1.conv1_downsample.conv.bias", "stage1.down_block1.conv2.conv.weight", "stage1.down_block1.conv2.conv.bias", "stage1.down_block2.conv1_downsample.conv.weight", "stage1.down_block2.conv1_downsample.conv.bias", "stage1.down_block2.conv2.conv.weight", "stage1.down_block2.conv2.conv.bias", "stage1.conv_bn1.conv.weight", "stage1.conv_bn1.conv.bias", "stage1.conv_bn2.conv.weight", "stage1.conv_bn2.conv.bias", "stage1.conv_bn3.conv.weight", "stage1.conv_bn3.conv.bias", "stage1.conv_bn4.conv.weight", "stage1.conv_bn4.conv.bias", "stage1.conv_bn5.conv.weight", "stage1.conv_bn5.conv.bias", "stage1.conv_bn6.conv.weight", "stage1.conv_bn6.conv.bias", "stage1.conv_bn7.conv.weight", "stage1.conv_bn7.conv.bias", "stage1.up_block1.conv1_upsample.conv.conv.weight", "stage1.up_block1.conv1_upsample.conv.conv.bias", "stage1.up_block1.conv2.conv.weight", "stage1.up_block1.conv2.conv.bias", "stage1.up_block2.conv1_upsample.conv.conv.weight", "stage1.up_block2.conv1_upsample.conv.conv.bias", "stage1.up_block2.conv2.conv.weight", "stage1.up_block2.conv2.conv.bias", "stage1.conv_to_rgb.conv.weight", "stage1.conv_to_rgb.conv.bias", "stage2.conv_conv1.conv.weight", "stage2.conv_conv1.conv.bias", "stage2.conv_down_block1.conv1_downsample.conv.weight", "stage2.conv_down_block1.conv1_downsample.conv.bias", "stage2.conv_down_block1.conv2.conv.weight", "stage2.conv_down_block1.conv2.conv.bias", "stage2.conv_down_block2.conv1_downsample.conv.weight", "stage2.conv_down_block2.conv1_downsample.conv.bias", "stage2.conv_down_block2.conv2.conv.weight", "stage2.conv_down_block2.conv2.conv.bias", "stage2.conv_conv_bn1.conv.weight", "stage2.conv_conv_bn1.conv.bias", "stage2.conv_conv_bn2.conv.weight", "stage2.conv_conv_bn2.conv.bias", "stage2.conv_conv_bn3.conv.weight", "stage2.conv_conv_bn3.conv.bias", "stage2.conv_conv_bn4.conv.weight", "stage2.conv_conv_bn4.conv.bias", "stage2.conv_conv_bn5.conv.weight", "stage2.conv_conv_bn5.conv.bias", "stage2.ca_conv1.conv.weight", "stage2.ca_conv1.conv.bias", "stage2.ca_down_block1.conv1_downsample.conv.weight", "stage2.ca_down_block1.conv1_downsample.conv.bias", "stage2.ca_down_block1.conv2.conv.weight", "stage2.ca_down_block1.conv2.conv.bias", "stage2.ca_down_block2.conv1_downsample.conv.weight", "stage2.ca_down_block2.conv1_downsample.conv.bias", "stage2.ca_down_block2.conv2.conv.weight", "stage2.ca_down_block2.conv2.conv.bias", "stage2.ca_conv_bn1.conv.weight", "stage2.ca_conv_bn1.conv.bias", "stage2.ca_conv_bn4.conv.weight", "stage2.ca_conv_bn4.conv.bias", "stage2.ca_conv_bn5.conv.weight", "stage2.ca_conv_bn5.conv.bias", "stage2.conv_bn6.conv.weight", "stage2.conv_bn6.conv.bias", "stage2.conv_bn7.conv.weight", "stage2.conv_bn7.conv.bias", "stage2.up_block1.conv1_upsample.conv.conv.weight", "stage2.up_block1.conv1_upsample.conv.conv.bias", "stage2.up_block1.conv2.conv.weight", "stage2.up_block1.conv2.conv.bias", "stage2.up_block2.conv1_upsample.conv.conv.weight", "stage2.up_block2.conv1_upsample.conv.conv.bias", "stage2.up_block2.conv2.conv.weight", "stage2.up_block2.conv2.conv.bias", "stage2.conv_to_rgb.conv.weight", "stage2.conv_to_rgb.conv.bias". ,你好,帮忙看下,好像是模型不太对?谢谢
from deepfillv2-pytorch.
@nipponjo load model error
from deepfillv2-pytorch.
The pretrained weights only work with the models in 'networks_tf.py'. You can include --tfmodel e.g:
python test.py --tfmodel --image examples/inpaint/case1.png --mask examples/inpaint/case1_mask.png --out examples/inpaint/case1_out_test.png --checkpoint pretrained/states_tf_places2.pth
to test with the pretrained weights.
from deepfillv2-pytorch.
@nipponjo ok, thank u
from deepfillv2-pytorch.
Related Issues (20)
- Export to onnx HOT 8
- how to generate test masks? HOT 5
- Where can I download the states_tf_places2.pth file? HOT 2
- Questions in the Learning Process HOT 1
- Question about train.yaml HOT 1
- How can i export pytorch model to coreml model
- Error during Core ML conversion
- Grayscale conversion HOT 4
- How to use muti GPU training?
- Pretrained models HOT 1
- Why use a grid during inference but not during training ?
- Is the test.ipynb up-to-date ?
- The object does not get removed but gets filled with noise on running test.py HOT 7
- How to set the train and value folder?
- 系统找不到指定的文件。: 'app/frontend/build/c_hello'
- training time and convergence HOT 8
- Can you please create new CoreML model ? HOT 1
- How to run with cpu? HOT 2
- An error HOT 1
- Why do I train my dataset, the output picture is just masked and not fixed, and 300,000 epochs are trained like this? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from deepfillv2-pytorch.