I'm not sure how to get dreamer to work for Atari. Running the following command
Results in a crash with the following trace. The environment seems to output an unexpected array named orientations. Any ideas on what the fix might be? And what is the recommended way to install atari?
Simulating agent for 4994812 steps.
Traceback (most recent call last):
File "dreamer.py", line 468, in <module>
main(parser.parse_args())
File "dreamer.py", line 440, in main
agent = Dreamer(config, datadir, actspace, writer)
File "dreamer.py", line 108, in __init__
self._build_model()
File "dreamer.py", line 244, in _build_model
self.train(next(self._dataset))
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/distribute/input_lib.py", line 296, in __next__
return self.get_next()
File "/home//miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/distribute/input_lib.py", line 328, in get_next
global_has_value, replicas = _get_next_as_optional(self, self._strategy)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/distribute/input_lib.py", line 192, in _get_next_as_optional
Skipped short episode of length 0.
iterator._iterators[i].get_next_as_list(new_name)) # pylint: disable=protected-access
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/distribute/input_lib.py", line 1132, in get_next_as_list
data_list = self._iterator.get_next_as_optional()
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/ops/multi_device_iterator_ops.py", line 601, in get_next_as_optional
iterator_ops.get_next_as_optional(self._device_iterators[i]))
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/ops/iterator_ops.py", line 833, in get_next_as_optional
Skipped short episode of length 0.
iterator.element_spec)), iterator.element_spec)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/ops/gen_dataset_ops.py", line 2444, in iterator_get_next_as_optional
_ops.raise_from_not_ok_status(e, name)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/framework/ops.py", line 6653, in raise_from_not_ok_status
Skipped short episode of length 0.
six.raise_from(core._status_to_exception(e.code, message), None)
File "<string>", line 3, in raise_from
Skipped short episode of length 0.
tensorflow.python.framework.errors_impl.InvalidArgumentError: TypeError: `generator` yielded an element that did not match the expected structure. The expected structure was {'image': dtype('uint8'), 'action': dtype('float16'), 'reward': dtype('float16'), 'discount': dtype('float16')}, but the yielded element was {'orientations': array([[-1.8042e-01, -9.8340e-01, 1.3806e-01, -9.9023e-01, 1.2341e-01,
-9.9219e-01, 7.9688e-01, -6.0449e-01, -6.5283e-01, -7.5781e-01,
9.2041e-01, -3.9136e-01, 9.9902e-01, 4.3976e-02],
[-1.4453e-01, -9.8975e-01, -3.6102e-02, -9.9951e-01, 2.0496e-01,
-9.7900e-01, 8.4912e-01, -5.2832e-01, -
....
.0437 , 0.04324, 0.042 , 0.04102, 0.04037, 0.04968, 0.118 ,
0.0898 , 0.07574, 0.087 , 0.0953 , 0.10486, 0.138 , 0.1825 ,
0.1633 , 0.1134 , 0.04486, 0.04956, 0.0498 , 0.04617, 0.03845,
0.03317], dtype=float16), 'discount': array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.],
dtype=float16)}.
Traceback (most recent call last):
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/ops/dataset_ops.py", line 791, in generator_py_func
flattened_values = nest.flatten_up_to(output_types, values)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/util/nest.py", line 396, in flatten_up_to
assert_shallow_structure(shallow_tree, input_tree)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/util/nest.py", line 311, in assert_shallow_structure
% (len(input_tree), len(shallow_tree)))
ValueError: The two structures don't have the same sequence length. Input structure has length 7, while shallow structure has length 4.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/ops/script_ops.py", line 243, in __call__
ret = func(*args)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/autograph/impl/api.py", line 309, in wrapper
return func(*args, **kwargs)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/ops/dataset_ops.py", line 796, in generator_py_func
"element was %s." % (output_types, values)), sys.exc_info()[2])
File "/home/.local/lib/python3.7/site-packages/six.py", line 702, in reraise
raise value.with_traceback(tb)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/ops/dataset_ops.py", line 791, in generator_py_func
flattened_values = nest.flatten_up_to(output_types, values)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/util/nest.py", line 396, in flatten_up_to
assert_shallow_structure(shallow_tree, input_tree)
File "/home/miniconda3_march2020/envs/dreamer/lib/python3.7/site-packages/tensorflow/python/data/util/nest.py", line 311, in assert_shallow_structure
% (len(input_tree), len(shallow_tree)))
TypeError: `generator` yielded an element that did not match the expected structure. The expected structure was {'image': dtype('uint8'), 'action': dtype('float16'), 'reward': dtype('float16'), 'discount': dtype('float16')}, but the yielded element was {'orientations': array([[-1.8042e-01, -9.8340e-01, 1.3806e-01, -9.9023e-01, 1.2341e-01,
-9.9219e-01, 7.9688e-01, -6.0449e-01, -6.5283e-01, -7.5781e-01,
9.2041e-01, -3.9136e-01, 9.9902e-01, 4.3976e-02],
[-1.4453e-01, -9.8975e-01, -3.6102e-02, -9.9951e-01, 2.0496e-01,
-9.7900e-01, 8.4912e-01, -5.2832e-01, -7.6025e-01, -6.4990e-01,
8.6963e-01, -4.9341e-01, 9.9805e-01, 6.0699e-02],
[ 1.7383e-01, -9.8486e-01, -4.8145e-01, -8.7646e-01, 3.6279e-01
...
33 , 0.1134 , 0.04486, 0.04956, 0.0498 , 0.04617, 0.03845,
0.03317], dtype=float16), 'discount': array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.],
dtype=float16)}.
[[{{node PyFunc}}]]
[[MultiDeviceIteratorGetNextFromShard]]
[[RemoteCall]] [Op:IteratorGetNextAsOptional]Skipped short episode of length 0.
Skipped short episode of length 0.