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

'float' object cannot be interpreted as an integer #49

Open
xiaolanke opened this issue Jul 8, 2019 · 1 comment
Open

'float' object cannot be interpreted as an integer #49

xiaolanke opened this issue Jul 8, 2019 · 1 comment

Comments

@xiaolanke
Copy link

Traceback (most recent call last):
File "main.py", line 83, in
tf.app.run()
File "/home/xiaolan2/folder/project/temp/hone/xiaolan2/folder/project/anaconda3/envs/yourenvname/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 40, in run
_run(main=main, argv=argv, flags_parser=_parse_flags_tolerate_undef)
File "/home/xiaolan2/folder/project/temp/hone/xiaolan2/folder/project/anaconda3/envs/yourenvname/lib/python3.6/site-packages/absl/app.py", line 300, in run
_run_main(main, args)
File "/home/xiaolan2/folder/project/temp/hone/xiaolan2/folder/project/anaconda3/envs/yourenvname/lib/python3.6/site-packages/absl/app.py", line 251, in _run_main
sys.exit(main(argv))
File "main.py", line 57, in main
denoiser_train(model, lr=lr)
File "main.py", line 25, in denoiser_train
denoiser.train(eval_files, noisy_eval_files, batch_size=args.batch_size, ckpt_dir=args.ckpt_dir, epoch=args.epoch, lr=lr)
File "/mnt/project/grp_202/xiaolan2/DnCNN-tensorflow/model.py", line 114, in train
ind1 = range(res.shape[0]/2)
TypeError: 'float' object cannot be interpreted as an integer

@FYJ112233
Copy link

ind1 = range(resform[0]//2);
in python3 , // instead of /

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

2 participants