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
Traceback (most recent call last):
File "train.py", line 35, in
mine = Trainer(p)
File "/data/src/trainer.py", line 111, in init
size=p["size"][0], backbone_pretrained=p["backbone_pretrained"]
File "/data/src/model/fcanet.py", line 295, in init
resnet.load_pretrained_model(backbone_pretrained)
File "/data/src/model/res2net.py", line 267, in load_pretrained_model
tmp[:, :3, :, :] = parameter_dict["conv1_0.weight"]
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/common/tensor.py", line 344, in setitem
out = tensor_operator_registry.get('setitem')(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 67, in _tensor_setitem
return tensor_setitem_by_tuple(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 803, in tensor_setitem_by_tuple
return tensor_setitem_by_tuple_with_tensor(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 956, in tensor_setitem_by_tuple_with_tensor
tuple_index, value, idx_advanced = remove_expanded_dims(tuple_index, F.shape(data), value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/compile_utils.py", line 1156, in remove_expanded_dims
value = F.reshape(value, value_shape)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/function/array_func.py", line 857, in reshape
return reshape(input_x, input_shape)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/primitive.py", line 294, in call
return _run_op(self, self.name, args)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/common/api.py", line 98, in wrapper
results = fn(*arg, **kwargs)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/primitive.py", line 748, in _run_op
output = real_run_op(obj, op_name, args)
RuntimeError: For 'Reshape', the size of 'input_x': {3456} is not equal to the size of the first output: {5760}
I use the dataset you provided,but I can't train.How to solve this problem?
root@0563a279aa9b:/data# DEVICE_ID=0 python train.py
Start time : 2022-09-22 08:07:09
infos : {'dataset_path': './dataset/', 'backbone_pretrained': './src/model/res2net_pretrained.ckpt', 'dataset_train': 'PASCAL_SBD', 'datasets_val': ['GrabCut', 'Berkeley'], 'epochs': 33, 'train_only_epochs': 32, 'val_robot_interval': 1, 'lr': 0.007, 'batch_size': 8, 'max_num': 0, 'size': (384, 384), 'device': 'CPU', 'num_workers': 4, 'itis_pro': 0.7, 'max_point_num': 20, 'record_point_num': 5, 'pred_tsh': 0.5, 'miou_target': [0.9, 0.9], 'resume': None, 'snapshot_path': './snapshot'}
Traceback (most recent call last):
File "train.py", line 35, in
mine = Trainer(p)
File "/data/src/trainer.py", line 111, in init
size=p["size"][0], backbone_pretrained=p["backbone_pretrained"]
File "/data/src/model/fcanet.py", line 295, in init
resnet.load_pretrained_model(backbone_pretrained)
File "/data/src/model/res2net.py", line 267, in load_pretrained_model
tmp[:, :3, :, :] = parameter_dict["conv1_0.weight"]
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/common/tensor.py", line 344, in setitem
out = tensor_operator_registry.get('setitem')(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 67, in _tensor_setitem
return tensor_setitem_by_tuple(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 803, in tensor_setitem_by_tuple
return tensor_setitem_by_tuple_with_tensor(self, index, value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/_compile_utils.py", line 956, in tensor_setitem_by_tuple_with_tensor
tuple_index, value, idx_advanced = remove_expanded_dims(tuple_index, F.shape(data), value)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/composite/multitype_ops/compile_utils.py", line 1156, in remove_expanded_dims
value = F.reshape(value, value_shape)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/function/array_func.py", line 857, in reshape
return reshape(input_x, input_shape)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/primitive.py", line 294, in call
return _run_op(self, self.name, args)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/common/api.py", line 98, in wrapper
results = fn(*arg, **kwargs)
File "/usr/local/python-3.7.5/lib/python3.7/site-packages/mindspore/ops/primitive.py", line 748, in _run_op
output = real_run_op(obj, op_name, args)
RuntimeError: For 'Reshape', the size of 'input_x': {3456} is not equal to the size of the first output: {5760}
mindspore/ccsrc/plugin/device/cpu/kernel/memcpy_cpu_kernel.cc:37 Launch
The text was updated successfully, but these errors were encountered: