rwightman / udacity-driving-reader

Quick docker based reader for udacity rosbag self-driving dataset. Dumps to png/jpg + csv or Tensorflow examples.
Apache License 2.0
162 stars 64 forks source link

bag2tf.py: Error when number of images is below 6000 #7

Open surfertas opened 6 years ago

surfertas commented 6 years ago

Thank you very much for this script. Just a heads up that for small data sets, sub 6000 images, the user will encounter an error per below. Its easy to debug, but a warning might help future users. Thanks again.

File "script/bag2tf.py", line 475, in main splits=split_list, center_only=center_only, debug_print=debug_print) File "script/bag2tf.py", line 207, in init writer = ShardWriter(self._outdir, s[0], scaled_images, max_num_shards=scaled_shards) File "script/bag2tf.py", line 135, in init self.num_entries_per_shard = num_entries // max_num_shards ZeroDivisionError: float divmod()

Tosha-beep commented 2 years ago

Hello! I got the same error, could you please share how you solved this problem? Very appreciated