Open namedysx opened 5 years ago
@namedysx thank you for your reporting.
This is cause of
https://github.com/terasakisatoshi/chainer-food-101/blob/master/dataset.py#L91
, so removing this line will resolve your error.
I have a long business trip for now. I can't fix it right away. If I go back my home, I will fix it. Thank you.
@namedysx thank you for your reporting.
This is cause of
https://github.com/terasakisatoshi/chainer-food-101/blob/master/dataset.py#L91
, so removing this line will resolve your error.
I have a long business trip for now. I can't fix it right away. If I go back my home, I will fix it. Thank you. thanks for your reply! I had removed this line, but the error remain. return that, D:\project\chainer-food-101>python train.py --device 0 --epoch 100 --destination trained multiplier 1.0 model_name mv2 destination trained seed 12345 dataset food-101 batch_size 32 device 0 resume epoch 100 INFO:dataset:bread_pudding/1375816 is in BLACKLIST INFO:dataset:lasagna/3787908 is in BLACKLIST INFO:dataset:steak/1340977 is in BLACKLIST Exception in thread Thread-1: Traceback (most recent call last): File "D:\anaconda\lib\threading.py", line 914, in _bootstrap_inner self.run() File "D:\anaconda\lib\threading.py", line 862, in run self._target(*self._args, **self._kwargs) File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 401, in fetch_batch batch_ret[0] = [self.dataset[idx] for idx in indices] File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 401, in
batch_ret[0] = [self.dataset[idx] for idx in indices] File "D:\anaconda\lib\site-packages\chainer\dataset\dataset_mixin.py", line 67, in getitem return self.get_example(index) File "D:\anaconda\lib\site-packages\chainer\datasets\sub_dataset.py", line 76, in get_example return self._dataset[index] File "D:\anaconda\lib\site-packages\chainer\dataset\dataset_mixin.py", line 67, in getitem return self.get_example(index) File "D:\project\chainer-food-101\dataset.py", line 96, in get_example image = preprocess(image, self.model_name) File "D:\project\chainer-food-101\dataset.py", line 40, in preprocess image /= 128. TypeError: ufunc 'true_divide' output (typecode 'd') could not be coerced to provided output parameter (typecode 'B') according to the casting rule ''same_kind''
Exception in main training loop: 'NoneType' object is not iterable
Traceback (most recent call last):
File "D:\anaconda\lib\site-packages\chainer\training\trainer.py", line 315, in run
update()
File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 165, in update
self.update_core()
File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 170, in update_core
batch = iterator.next()
File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 148, in next
self.dataset_timeout)
File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 417, in measure
self.mem_size = max(map(_measure, batch))
Will finalize trainer extensions and updater before reraising the exception.
Traceback (most recent call last):
File "train.py", line 137, in
Is it cant run on my PC?
The error msg you reported shows
https://github.com/terasakisatoshi/chainer-food-101/blob/master/dataset.py#L40
get error.
Could you replace the line as follow:
Before
image /= 128.
After
image = image/128.
I hope it will be all right
Hi Y'all, I am facing a similar issue. https://github.com/atom2k17/Basketball-ChainerCV/blob/master/basketball.py TypeError: 'NoneType' object is not iterable I would like to know what is causing the training data to show as None even though the train_dataset format is correct, before being passed through Data Transformation process. Thanks.
Sorry everyone, I could not have fixed these issue because of my long illness.
Dear @namedysx and @atom2k17
I'm so sorry my delay response.
I've just created revised repository named chainer-food-101-revised this repository revise this repository. Since the current Chainer version is 6.2.0 I recommend try new one.
Traceback (most recent call last): File "D:\anaconda\lib\threading.py", line 914, in _bootstrap_inner self.run() File "D:\anaconda\lib\threading.py", line 862, in run self._target(*self._args, *self._kwargs) File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 401, in fetch_batch batch_ret[0] = [self.dataset[idx] for idx in indices] File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 401, in
batch_ret[0] = [self.dataset[idx] for idx in indices]
File "D:\anaconda\lib\site-packages\chainer\dataset\dataset_mixin.py", line 67, in getitem
return self.get_example(index)
File "D:\anaconda\lib\site-packages\chainer\datasets\sub_dataset.py", line 76, in get_example
return self._dataset[index]
File "D:\anaconda\lib\site-packages\chainer\dataset\dataset_mixin.py", line 67, in getitem
return self.get_example(index)
File "D:\project\chainer-food-101\dataset.py", line 91, in get_example
image = transforms.pca_lighting(image, 76.5)
File "D:\anaconda\lib\site-packages\chainercv\transforms\image\pca_lighting.py", line 48, in pca_lighting
img += eigen_vector.dot(eigen_value alpha).reshape((-1, 1, 1))
TypeError: Cannot cast ufunc add output from dtype('float64') to dtype('uint8') with casting rule 'same_kind'
Exception in main training loop: 'NoneType' object is not iterable Traceback (most recent call last): File "D:\anaconda\lib\site-packages\chainer\training\trainer.py", line 315, in run update() File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 165, in update self.update_core() File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 170, in update_core batch = iterator.next() File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 148, in next self.dataset_timeout) File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 417, in measure self.mem_size = max(map(_measure, batch)) Will finalize trainer extensions and updater before reraising the exception. Traceback (most recent call last): File "train.py", line 137, in
main()
File "train.py", line 133, in main
train(args)
File "train.py", line 106, in train
trainer.run()
File "D:\anaconda\lib\site-packages\chainer\training\trainer.py", line 329, in run
six.reraise(*sys.exc_info())
File "D:\anaconda\lib\site-packages\six.py", line 693, in reraise
raise value
File "D:\anaconda\lib\site-packages\chainer\training\trainer.py", line 315, in run
update()
File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 165, in update
self.update_core()
File "D:\anaconda\lib\site-packages\chainer\training\updaters\standard_updater.py", line 170, in update_core
batch = iterator.next()
File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 148, in next
self.dataset_timeout)
File "D:\anaconda\lib\site-packages\chainer\iterators\multiprocess_iterator.py", line 417, in measure
self.mem_size = max(map(_measure, batch))
TypeError: 'NoneType' object is not iterable