videogan icon indicating copy to clipboard operation
videogan copied to clipboard

flag type error in --video_dim

Open Megacrafter127 opened this issue 6 years ago • 2 comments

absl.flags._exceptions.IllegalFlagValueError: flag --video_dim=[32, 64, 64, 3]: Expect argument to be a string or int, found <type 'list'>

Python v2.7.12 TensorFlow v1.9.0 (gpu accelerated) [docker image tensorflow/tensorflow:latest-gpu]

CMD: python main.py

any suggested fixes or workarounds?

Megacrafter127 avatar Aug 09 '18 12:08 Megacrafter127

you can comment that out, initialize a new variable video_dim = [32, 64, 64, 3] and which calling the constructor, instead of passing FLAG.video_dim, pass video_dim as the parameter. It might work

Prakharm007 avatar Apr 02 '19 19:04 Prakharm007

after commenting the flag and passing video_dim as parameter is still not effective. please resolve the issue

Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/absl/flags/_flag.py", line 181, in _parse return self.parser.parse(argument) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_argument_parser.py", line 152, in parse val = self.convert(argument) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_argument_parser.py", line 268, in convert type(argument))) TypeError: Expect argument to be a string or int, found <class 'float'>

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "main.py", line 21, in flags.DEFINE_integer("lambd", 0.0, "The value of sparsity regularizer") File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/platform/flags.py", line 58, in wrapper return original_function(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_defines.py", line 315, in DEFINE_integer DEFINE(parser, name, default, help, flag_values, serializer, **args) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_defines.py", line 81, in DEFINE DEFINE_flag(_flag.Flag(parser, serializer, name, default, help, **args), File "/usr/local/lib/python3.6/dist-packages/absl/flags/_flag.py", line 110, in init self._set_default(default) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_flag.py", line 211, in _set_default self.default = self._parse(value) File "/usr/local/lib/python3.6/dist-packages/absl/flags/_flag.py", line 184, in _parse 'flag --%s=%s: %s' % (self.name, argument, e)) absl.flags._exceptions.IllegalFlagValueError: flag --lambd=0.0: Expect argument to be a string or int, found <class 'float'>

ghost avatar May 18 '19 00:05 ghost