Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pretrained models #11

Open
xiaodongpo opened this issue Jan 12, 2025 · 1 comment
Open

pretrained models #11

xiaodongpo opened this issue Jan 12, 2025 · 1 comment

Comments

@xiaodongpo
Copy link

Hello,could you please tell me how to use the pretrained models(flatnet_separable_pointGrey_randomInit or flatnet_separable_pointGrey_transposeInit) to train FlatNet-sep. Thank you!

@xiaodongpo
Copy link
Author

run main.py to train from scratch may not need the pretrain models, but when i training, there is error: ../aten/src/ATen/native/cuda/Loss.cu:95: operator(): block: [0,0,0], thread: [2,0,0] Assertion target_val >= zero && target_val <= one failed.
Traceback (most recent call last):
File "main.py", line 156, in
disc_err = train_discriminator_epoch(gen, dis, optim_dis, dis_criterion, train_loader, opt.disPreEpochs, disc_err, device)
File "/root/autodl-tmp/Flatnet/flatnet-flatnet-sep/fns_all.py", line 36, in train_discriminator_epoch
dis_loss = criterion(dis(high_res_real), target_real) + criterion(dis(Variable(high_res_fake.data)), target_fake)
File "/root/miniconda3/envs/flatnet/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1553, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/root/miniconda3/envs/flatnet/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1562, in _call_impl
return forward_call(*args, **kwargs)
File "/root/miniconda3/envs/flatnet/lib/python3.8/site-packages/torch/nn/modules/loss.py", line 621, in forward
return F.binary_cross_entropy(input, target, weight=self.weight, reduction=self.reduction)
File "/root/miniconda3/envs/flatnet/lib/python3.8/site-packages/torch/nn/functional.py", line 3172, in binary_cross_entropy
return torch._C._nn.binary_cross_entropy(input, target, weight, reduction_enum)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant