You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After successfully training StyleGAN 2 on a dataset of (1024, 768), I tried using the network for projecting real images into latent space. Unfortunately I'm getting an error as shown below. Traceback (most recent call last):
File "run_projector.py", line 146, in
main()
File "run_projector.py", line 141, in main
dnnlib.submit_run(sc, func_name_map[subcmd], **kwargs)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/submit.py", line 343, in submit_run
return farm.submit(submit_config, host_run_dir)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/internal/local.py", line 22, in submit
return run_wrapper(submit_config)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/submit.py", line 280, in run_wrapper
run_func_obj(**submit_config.run_func_kwargs)
File "/home/dayu/D/src2000/stylegan2_skyfly/run_projector.py", line 59, in project_real_images
proj.set_network(Gs)
File "/home/dayu/D/src2000/stylegan2_skyfly/projector.py", line 103, in set_network
proc_images_expr = tf.reduce_mean(tf.reshape(proc_images_expr, [-1, sh[1], sh[2] // factor, factor, sh[2] // factor, factor]), axis=[3,5])
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/ops/gen_array_ops.py", line 7715, in reshape
"Reshape", tensor=tensor, shape=shape, name=name)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/op_def_library.py", line 788, in _apply_op_helper
op_def=op_def)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/util/deprecation.py", line 507, in new_func
return func(*args, **kwargs)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 3616, in create_op
op_def=op_def)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 2027, in init
control_input_ops)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 1867, in _create_c_op
raise ValueError(str(e))
ValueError: Dimension size must be evenly divisible by 3145728 but is 2359296 for 'Reshape' (op: 'Reshape') with input shapes: [1,3,1024,768], [6] and with input tensors computed as partial shapes: input[1] = [?,3,256,4,256,4].
The text was updated successfully, but these errors were encountered:
After successfully training StyleGAN 2 on a dataset of (1024, 768), I tried using the network for projecting real images into latent space. Unfortunately I'm getting an error as shown below. Traceback (most recent call last):
File "run_projector.py", line 146, in
main()
File "run_projector.py", line 141, in main
dnnlib.submit_run(sc, func_name_map[subcmd], **kwargs)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/submit.py", line 343, in submit_run
return farm.submit(submit_config, host_run_dir)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/internal/local.py", line 22, in submit
return run_wrapper(submit_config)
File "/home/dayu/D/src2000/stylegan2_skyfly/dnnlib/submission/submit.py", line 280, in run_wrapper
run_func_obj(**submit_config.run_func_kwargs)
File "/home/dayu/D/src2000/stylegan2_skyfly/run_projector.py", line 59, in project_real_images
proj.set_network(Gs)
File "/home/dayu/D/src2000/stylegan2_skyfly/projector.py", line 103, in set_network
proc_images_expr = tf.reduce_mean(tf.reshape(proc_images_expr, [-1, sh[1], sh[2] // factor, factor, sh[2] // factor, factor]), axis=[3,5])
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/ops/gen_array_ops.py", line 7715, in reshape
"Reshape", tensor=tensor, shape=shape, name=name)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/op_def_library.py", line 788, in _apply_op_helper
op_def=op_def)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/util/deprecation.py", line 507, in new_func
return func(*args, **kwargs)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 3616, in create_op
op_def=op_def)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 2027, in init
control_input_ops)
File "/home/dayu/anaconda3/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 1867, in _create_c_op
raise ValueError(str(e))
ValueError: Dimension size must be evenly divisible by 3145728 but is 2359296 for 'Reshape' (op: 'Reshape') with input shapes: [1,3,1024,768], [6] and with input tensors computed as partial shapes: input[1] = [?,3,256,4,256,4].
The text was updated successfully, but these errors were encountered: