Always waiting for new checkpoint
I have converted my dataset to tfrecord format. When i trying to eval my dataset,i used this command
python efficientdet/main.py --mode=eval \
--model_name=efficientdet-d4 --model_dir=/tmp/efficientdet/efficientdet-d4 \
--validation_file_pattern=pascal_val* \
--val_json_file=coco_2.json \
--hparams="use_bfloat16=false" --use_tpu=False
Then i stopped at
2020-04-01 02:59:35.879711: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcudart.so.10.1
WARNING:tensorflow:From /usr/local/lib/python3.6/dist-packages/tensorflow/python/compat/v2_compat.py:96: disable_resource_variables (from tensorflow.python.ops.variable_scope) is deprecated and will be removed in a future version.
Instructions for updating:
non-resource variables are not supported in the long term
WARNING:tensorflow:From efficientdet/main.py:222: The name tf.estimator.tpu.TPUConfig is deprecated. Please use tf.compat.v1.estimator.tpu.TPUConfig instead.
W0401 02:59:55.120239 139857476130688 module_wrapper.py:138] From efficientdet/main.py:222: The name tf.estimator.tpu.TPUConfig is deprecated. Please use tf.compat.v1.estimator.tpu.TPUConfig instead.
WARNING:tensorflow:From efficientdet/main.py:227: The name tf.estimator.tpu.InputPipelineConfig is deprecated. Please use tf.compat.v1.estimator.tpu.InputPipelineConfig instead.
W0401 02:59:55.120502 139857476130688 module_wrapper.py:138] From efficientdet/main.py:227: The name tf.estimator.tpu.InputPipelineConfig is deprecated. Please use tf.compat.v1.estimator.tpu.InputPipelineConfig instead.
WARNING:tensorflow:From efficientdet/main.py:230: The name tf.estimator.tpu.RunConfig is deprecated. Please use tf.compat.v1.estimator.tpu.RunConfig instead.
W0401 02:59:55.120692 139857476130688 module_wrapper.py:138] From efficientdet/main.py:230: The name tf.estimator.tpu.RunConfig is deprecated. Please use tf.compat.v1.estimator.tpu.RunConfig instead.
I0401 02:59:55.120970 139857476130688 main.py:242] {'name': 'efficientdet-d4', 'image_size': 1024, 'input_rand_hflip': True, 'train_scale_min': 0.1, 'train_scale_max': 2.0, 'autoaugment_policy': None, 'num_classes': 90, 'skip_crowd_during_training': True, 'min_level': 3, 'max_level': 7, 'num_scales': 3, 'aspect_ratios': [(1.0, 1.0), (1.4, 0.7), (0.7, 1.4)], 'anchor_scale': 4.0, 'is_training_bn': True, 'momentum': 0.9, 'learning_rate': 0.08, 'lr_warmup_init': 0.008, 'lr_warmup_epoch': 1.0, 'first_lr_drop_epoch': 200.0, 'second_lr_drop_epoch': 250.0, 'clip_gradients_norm': 10.0, 'num_epochs': 15, 'alpha': 0.25, 'gamma': 1.5, 'delta': 0.1, 'box_loss_weight': 50.0, 'weight_decay': 4e-05, 'use_bfloat16': False, 'box_class_repeats': 4, 'fpn_cell_repeats': 7, 'fpn_num_filters': 224, 'separable_conv': True, 'apply_bn_for_resampling': True, 'conv_after_downsample': False, 'conv_bn_relu_pattern': False, 'use_native_resize_op': False, 'pooling_type': None, 'fpn_name': None, 'fpn_config': None, 'survival_prob': None, 'lr_decay_method': 'cosine', 'moving_average_decay': 0.9998, 'ckpt_var_scope': None, 'var_exclude_expr': '.*/class-predict/.*', 'backbone_name': 'efficientnet-b4', 'backbone_config': None, 'resnet_depth': 50, 'model_name': 'efficientdet-d4', 'iterations_per_loop': 100, 'model_dir': '/tmp/efficientdet/efficientdet-d4', 'num_shards': 8, 'num_examples_per_epoch': 120000, 'use_tpu': False, 'backbone_ckpt': '', 'ckpt': None, 'val_json_file': 'coco_2.json', 'testdev_dir': None, 'mode': 'eval'}
WARNING:tensorflow:From efficientdet/main.py:294: The name tf.estimator.tpu.TPUEstimator is deprecated. Please use tf.compat.v1.estimator.tpu.TPUEstimator instead.
W0401 02:59:55.121169 139857476130688 module_wrapper.py:138] From efficientdet/main.py:294: The name tf.estimator.tpu.TPUEstimator is deprecated. Please use tf.compat.v1.estimator.tpu.TPUEstimator instead.
INFO:tensorflow:Using config: {'_model_dir': '/tmp/efficientdet/efficientdet-d4', '_tf_random_seed': None, '_save_summary_steps': 100, '_save_checkpoints_steps': None, '_save_checkpoints_secs': 600, '_session_config': allow_soft_placement: true
, '_keep_checkpoint_max': 5, '_keep_checkpoint_every_n_hours': 10000, '_log_step_count_steps': None, '_train_distribute': None, '_device_fn': None, '_protocol': None, '_eval_distribute': None, '_experimental_distribute': None, '_experimental_max_worker_delay_secs': None, '_session_creation_timeout_secs': 7200, '_service': None, '_cluster_spec': ClusterSpec({}), '_task_type': 'worker', '_task_id': 0, '_global_id_in_cluster': 0, '_master': '', '_evaluation_master': '', '_is_chief': True, '_num_ps_replicas': 0, '_num_worker_replicas': 1, '_tpu_config': TPUConfig(iterations_per_loop=100, num_shards=8, num_cores_per_replica=None, per_host_input_for_training=3, tpu_job_name=None, initial_infeed_sleep_secs=None, input_partition_dims=None, eval_training_input_configuration=2, experimental_host_call_every_n_steps=1), '_cluster': None}
I0401 02:59:55.121651 139857476130688 estimator.py:191] Using config: {'_model_dir': '/tmp/efficientdet/efficientdet-d4', '_tf_random_seed': None, '_save_summary_steps': 100, '_save_checkpoints_steps': None, '_save_checkpoints_secs': 600, '_session_config': allow_soft_placement: true
, '_keep_checkpoint_max': 5, '_keep_checkpoint_every_n_hours': 10000, '_log_step_count_steps': None, '_train_distribute': None, '_device_fn': None, '_protocol': None, '_eval_distribute': None, '_experimental_distribute': None, '_experimental_max_worker_delay_secs': None, '_session_creation_timeout_secs': 7200, '_service': None, '_cluster_spec': ClusterSpec({}), '_task_type': 'worker', '_task_id': 0, '_global_id_in_cluster': 0, '_master': '', '_evaluation_master': '', '_is_chief': True, '_num_ps_replicas': 0, '_num_worker_replicas': 1, '_tpu_config': TPUConfig(iterations_per_loop=100, num_shards=8, num_cores_per_replica=None, per_host_input_for_training=3, tpu_job_name=None, initial_infeed_sleep_secs=None, input_partition_dims=None, eval_training_input_configuration=2, experimental_host_call_every_n_steps=1), '_cluster': None}
INFO:tensorflow:_TPUContext: eval_on_tpu True
I0401 02:59:55.122611 139857476130688 tpu_context.py:216] _TPUContext: eval_on_tpu True
WARNING:tensorflow:eval_on_tpu ignored because use_tpu is False.
W0401 02:59:55.123078 139857476130688 tpu_context.py:218] eval_on_tpu ignored because use_tpu is False.
INFO:tensorflow:**Waiting for new checkpoint** at /tmp/efficientdet/efficientdet-d4
I0401 02:59:55.123164 139857476130688 checkpoint_utils.py:125] Waiting for new checkpoint at /tmp/efficientdet/efficientdet-d4
Please!
You need to download the latest Pretrained EfficientDet Checkpoints, https://storage.googleapis.com/cloud-tpu-checkpoints/efficientdet/coco/efficientdet-d0.tar.gz and then use -- ckpt= to specify it
You need to download the latest Pretrained EfficientDet Checkpoints, https://storage.googleapis.com/cloud-tpu-checkpoints/efficientdet/coco/efficientdet-d0.tar.gz and then use -- ckpt= to specify it
isn't it to unzip the tarfile adn use "--model_dir=" to specify it??
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
老哥有遇到:https://github.com/google/automl/issues/120#issue-591334088 这个问题吗?
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
另外就是我用BDD100K训练,现在预训练模型是coco上的,我训练不一样的数据集可以用吗? tf有没有自己去适应output不一样的机制?
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.

@ qtw1998不是--model_dir这个是用于存放你训练后保存模型的地址。
另外就是我用BDD100K训练,现在预训练模型是coco上的,我训练不一样的数据集可以用吗 ?
可以用的 只要num_classes=你现在所需要训练的类总和就行
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
python main.py --training_file_pattern=tfrecord/train* --model_name=efficientdet-d3 --model_dir=tmp/model --hparams="use_bfloat16=false, num_classes=6" --use_tpu=False --ckpt=tmp/efficientdet-d3 --validation_file_pattern=tfrecord/val* --val_json_file=tfrecord/annotations/val2017.json --mode='train_and_eval' --logdir=logs
这是我的训练命令 --model_dir=tmp/model 这个是我新建的一个文件夹 训练过程中 会把训练的模型存放在这个文件夹下面 而且我查看了其他人的训练命令 几乎都是这样的
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
python main.py --training_file_pattern=tfrecord/train* --model_name=efficientdet-d3 --model_dir=tmp/model --hparams="use_bfloat16=false, num_classes=6" --use_tpu=False --ckpt=tmp/efficientdet-d3 --validation_file_pattern=tfrecord/val* --val_json_file=tfrecord/annotations/val2017.json --mode='train_and_eval' --logdir=logs
这是我的训练命令 --model_dir=tmp/model 这个是我新建的一个文件夹 训练过程中 会把训练的模型存放在这个文件夹下面 而且我查看了其他人的训练命令 几乎都是这样的
2020-04-01 13:06:02.697149: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0374e00 of size 256 next 3439 2020-04-01 13:06:02.697431: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0374f00 of size 256 next 3440
2020-04-01 13:06:02.704638: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376c00 of size 256 next 3469 2020-04-01 13:06:02.704904: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376d00 of size 256 next 3470 2020-04-01 13:06:02.705134: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376e00 of size 256 next 3471 2020-04-01 13:06:02.705401: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376f00 of size 256 next 3472 2020-04-01 13:06:02.705683: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377000 of size 256 next 3473 2020-04-01 13:06:02.705937: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377100 of size 256 next 3474 2020-04-01 13:06:02.706170: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377200 of size 256 next 3475 2020-04-01 13:06:02.706446: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377300 of size 256 next 3476 2020-04-01 13:06:02.706662: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377400 of size 256 next 3477 2020-04-01 13:06:02.706964: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377500 of size 256 next 3478 2020-04-01 13:06:02.707195: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377600 of size 256 next 3479 2020-04-01 13:06:02.707448: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377700 of size 256 next 3480 2020-04-01 13:06:02.707703: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377800 of size 256 next 3481 2020-04-01 13:06:02.707978: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377900 of size 256 next 3482 2020-04-01 13:06:02.708240: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377a00 of size 256 next 3483 2020-04-01 13:06:02.708466: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377b00 of size 256 next 3484 2020-04-01 13:06:02.708658: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377c00 of size 256 next 3485 2020-04-01 13:06:02.708863: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377d00 of size 256 next 3486 2020-04-01 13:06:02.709047: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377e00 of size 256 next 3487 2020-04-01 13:06:02.709219: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377f00 of size 256 next 3488 2020-04-01 13:06:02.709371: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378000 of size 256 next 3489 2020-04-01 13:06:02.709541: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378100 of size 256 next 3490 2020-04-01 13:06:02.709745: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378200 of size 256 next 3491 2020-04-01 13:06:02.709904: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378300 of size 256 next 3492 2020-04-01 13:06:02.710073: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378400 of size 256 next 3493 2020-04-01 13:06:02.710259: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378500 of size 256 next 3494 2020-04-01 13:06:02.710439: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378600 of size 256 next 3495 2020-04-01 13:06:02.710608: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378700 of size 256 next 3496 2020-04-01 13:06:02.710867: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378800 of size 256 next 3497 2020-04-01 13:06:02.711020: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378900 of size 256 next 3498 2020-04-01 13:06:02.711183: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378a00 of size 256 next 3499 2020-04-01 13:06:02.711361: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378b00 of size 256 next 3500 2020-04-01 13:06:02.711547: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378c00 of size 256 next 3501 2020-04-01 13:06:02.711731: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378d00 of size 256 next 3502 2020-04-01 13:06:02.712008: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378e00 of size 256 next 3503 2020-04-01 13:06:02.712294: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378f00 of size 256 next 3504 2020-04-01 13:06:02.712563: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379000 of size 256 next 3505 2020-04-01 13:06:02.712888: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379100 of size 256 next 3506 2020-04-01 13:06:02.713179: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379200 of size 256 next 3507 2020-04-01 13:06:02.713436: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379300 of size 256 next 3508 2020-04-01 13:06:02.713685: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379400 of size 256 next 3509 2020-04-01 13:06:02.713907: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379500 of size 256 next 3510 2020-04-01 13:06:02.714102: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379600 of size 256 next 3511 2020-04-01 13:06:02.714287: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379700 of size 256 next 3512 2020-04-01 13:06:02.714443: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379800 of size 256 next 3513 2020-04-01 13:06:02.714592: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379900 of size 256 next 3514 2020-04-01 13:06:02.714902: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379a00 of size 256 next 3515 2020-04-01 13:06:02.715128: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379b00 of size 256 next 3516 2020-04-01 13:06:02.715363: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379c00 of size 256 next 3517 2020-04-01 13:06:02.715690: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379d00 of size 256 next 3518 2020-04-01 13:06:02.715873: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379e00 of size 256 next 3519 2020-04-01 13:06:02.716036: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379f00 of size 256 next 3520 2020-04-01 13:06:02.716230: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a000 of size 256 next 3521 2020-04-01 13:06:02.716421: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a100 of size 256 next 3522 2020-04-01 13:06:02.716592: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a200 of size 256 next 3523 2020-04-01 13:06:02.716856: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a300 of size 256 next 3524 2020-04-01 13:06:02.717047: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a400 of size 256 next 3525 2020-04-01 13:06:02.717221: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a500 of size 256 next 3526 2020-04-01 13:06:02.717412: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a600 of size 256 next 3527 2020-04-01 13:06:02.717557: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a700 of size 256 next 3528 2020-04-01 13:06:02.717741: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a800 of size 256 next 3529 2020-04-01 13:06:02.718013: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a900 of size 256 next 3530 e/bfc_allocator.cc:950] InUse at 2b3537165b00 of size 157286400 next 4426 2020-04-01 13:06:02.936237: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3540765b00 of size 157286400 next 4427 2020-04-01 13:06:02.936476: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3549d65b00 of size 39321600 next 4428 2020-04-01 13:06:02.936753: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b354c2e5b00 of size 39321600 next 4429 2020-04-01 13:06:02.937002: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b354e865b00 of size 39321600 next 4430 2020-04-01 13:06:02.937259: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3550de5b00 of size 39321600 next 4433 2020-04-01 13:06:02.937580: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3553365b00 of size 9830400 next 4434 2020-04-01 13:06:02.937812: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3553cc5b00 of size 9830400 next 4435 2020-04-01 13:06:02.938022: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3554625b00 of size 58982400 next 4438 2020-04-01 13:06:02.938227: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3557e65b00 of size 58982400 next 4439 2020-04-01 13:06:02.938457: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b355b6a5b00 of size 58982400 next 4440 2020-04-01 13:06:02.938698: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b355eee5b00 of size 58982400 next 4441 2020-04-01 13:06:02.938925: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3562725b00 of size 58982400 next 4442 2020-04-01 13:06:02.939158: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3565f65b00 of size 82552064 next 18446744073709551615 2020-04-01 13:06:02.939368: I tensorflow/core/common_runtime/bfc_allocator.cc:955] Summary of in-use Chunks by size: 2020-04-01 13:06:02.939599: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 2009 Chunks of size 256 totalling 502.2KiB 2020-04-01 13:06:02.940008: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1086 Chunks of size 512 totalling 543.0KiB 2020-04-01 13:06:02.940298: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 105 Chunks of size 768 totalling 78.8KiB 2020-04-01 13:06:02.940521: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 69 Chunks of size 1024 totalling 69.0KiB 2020-04-01 13:06:02.940767: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 22 Chunks of size 1280 totalling 27.5KiB 2020-04-01 13:06:02.941103: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 1536 totalling 10.5KiB 2020-04-01 13:06:02.941330: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 1792 totalling 1.8KiB 2020-04-01 13:06:02.941593: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 76 Chunks of size 2048 totalling 152.0KiB 2020-04-01 13:06:02.941914: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 2304 totalling 6.8KiB 2020-04-01 13:06:02.942163: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 2560 totalling 2.5KiB 2020-04-01 13:06:02.942429: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 73 Chunks of size 2816 totalling 200.8KiB 2020-04-01 13:06:02.942702: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 204 Chunks of size 3328 totalling 663.0KiB 2020-04-01 13:06:02.942955: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 27 Chunks of size 3584 totalling 94.5KiB 2020-04-01 13:06:02.943260: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 3840 totalling 3.8KiB 2020-04-01 13:06:02.943525: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 4096 totalling 4.0KiB 2020-04-01 13:06:02.943747: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 91 Chunks of size 4608 totalling 409.5KiB 2020-04-01 13:06:02.943998: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 5120 totalling 5.0KiB 2020-04-01 13:06:02.944239: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 5376 totalling 36.8KiB 2020-04-01 13:06:02.944492: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 6144 totalling 24.0KiB 2020-04-01 13:06:02.944706: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 19 Chunks of size 7680 totalling 142.5KiB 2020-04-01 13:06:02.944912: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 8704 totalling 34.0KiB 2020-04-01 13:06:02.945179: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 9216 totalling 36.0KiB 2020-04-01 13:06:02.945398: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 20 Chunks of size 9728 totalling 190.0KiB 2020-04-01 13:06:02.945629: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 12800 totalling 62.5KiB 2020-04-01 13:06:02.945843: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 17 Chunks of size 13824 totalling 229.5KiB 2020-04-01 13:06:02.946058: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 14080 totalling 68.8KiB 2020-04-01 13:06:02.946288: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 14592 totalling 114.0KiB 2020-04-01 13:06:02.946511: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 17408 totalling 170.0KiB 2020-04-01 13:06:02.946790: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 23040 totalling 90.0KiB 2020-04-01 13:06:02.947039: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 24064 totalling 164.5KiB 2020-04-01 13:06:02.947311: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 190 Chunks of size 30976 totalling 5.61MiB 2020-04-01 13:06:02.947528: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 43 Chunks of size 38400 totalling 1.57MiB 2020-04-01 13:06:02.947732: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 39424 totalling 385.0KiB 2020-04-01 13:06:02.947964: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 41472 totalling 162.0KiB 2020-04-01 13:06:02.948171: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 48128 totalling 188.0KiB 2020-04-01 13:06:02.948397: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 57600 totalling 225.0KiB 2020-04-01 13:06:02.948687: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 13 Chunks of size 67328 totalling 854.8KiB 2020-04-01 13:06:02.948929: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 69120 totalling 270.0KiB 2020-04-01 13:06:02.949151: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 26 Chunks of size 75264 totalling 1.87MiB 2020-04-01 13:06:02.949365: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 76800 totalling 300.0KiB 2020-04-01 13:06:02.949637: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 81152 totalling 79.2KiB 2020-04-01 13:06:02.949849: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 15 Chunks of size 112640 totalling 1.61MiB 2020-04-01 13:06:02.950106: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 13 Chunks of size 115200 totalling 1.43MiB 2020-04-01 13:06:02.950303: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 23 Chunks of size 153600 totalling 3.37MiB 2020-04-01 13:06:02.950550: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 215040 totalling 840.0KiB 2020-04-01 13:06:02.950784: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 32 Chunks of size 221184 totalling 6.75MiB 2020-04-01 13:06:02.951130: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 230400 totalling 900.0KiB 2020-04-01 13:06:02.951518: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 285184 totalling 1.36MiB 2020-04-01 13:06:02.951749: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 23 Chunks of size 301056 totalling 6.60MiB 2020-04-01 13:06:02.951973: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 324096 totalling 1.85MiB 2020-04-01 13:06:02.952190: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 516096 totalling 1.97MiB 2020-04-01 13:06:02.952484: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 614400 totalling 4.69MiB 2020-04-01 13:06:02.952703: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 29 Chunks of size 884736 totalling 24.47MiB 2020-04-01 13:06:02.952936: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 921600 totalling 3.52MiB 2020-04-01 13:06:02.953181: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 1296128 totalling 7.42MiB 2020-04-01 13:06:02.953483: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 1474560 totalling 5.62MiB 2020-04-01 13:06:02.953705: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 2457600 totalling 18.75MiB 2020-04-01 13:06:02.953915: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 3686400 totalling 10.55MiB 2020-04-01 13:06:02.954200: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 5184000 totalling 29.66MiB 2020-04-01 13:06:02.954427: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 2 Chunks of size 9830400 totalling 18.75MiB 2020-04-01 13:06:02.954670: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 19660800 totalling 18.75MiB 2020-04-01 13:06:02.954945: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 20736000 totalling 118.65MiB 2020-04-01 13:06:02.955140: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 26214400 totalling 250.00MiB 2020-04-01 13:06:02.955388: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 39321600 totalling 150.00MiB 2020-04-01 13:06:02.955650: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 52428800 totalling 300.00MiB 2020-04-01 13:06:02.955888: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 58982400 totalling 281.25MiB 2020-04-01 13:06:02.956125: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 80209664 totalling 76.49MiB 2020-04-01 13:06:02.956371: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 82552064 totalling 78.73MiB 2020-04-01 13:06:02.956600: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 82944000 totalling 395.51MiB 2020-04-01 13:06:02.956887: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 157286400 totalling 450.00MiB 2020-04-01 13:06:02.957131: I tensorflow/core/common_runtime/bfc_allocator.cc:962] Sum Total of in-use chunks: 2.23GiB 2020-04-01 13:06:02.957352: I tensorflow/core/common_runtime/bfc_allocator.cc:964] total_region_allocated_bytes_: 2397175808 memory_limit_: 2397175808 available bytes: 0 curr_region_allocation_bytes_: 4794351616 2020-04-01 13:06:02.957592: I tensorflow/core/common_runtime/bfc_allocator.cc:970] Stats: Limit: 2397175808 InUse: 2395943424 MaxInUse: 2395943424 NumAllocs: 4868 MaxAllocSize: 157286400
2020-04-01 13:06:02.958580: W tensorflow/core/common_runtime/bfc_allocator.cc:429] x***************************************************** 2020-04-01 13:06:02.960895: W tensorflow/core/framework/op_kernel.cc:1655] OP_REQUIRES failed at reduction_gpu_kernels.cu.h:917 : Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc INFO:tensorflow:training_loop marked as finished I0401 13:06:14.966216 47484351229632 error_handling.py:108] training_loop marked as finished WARNING:tensorflow:Reraising captured error W0401 13:06:14.983711 47484351229632 error_handling.py:142] Reraising captured error Traceback (most recent call last): File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1367, in _do_call return fn(*args) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1352, in _run_fn target_list, run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1445, in _call_tf_sessionrun run_metadata) tensorflow.python.framework.errors_impl.ResourceExhaustedError: 2 root error(s) found. (0) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[{{node efficientnet-b1/model/blocks_3/se/Mean}}]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
[[strided_slice_6/_18487]]
Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
(1) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[{{node efficientnet-b1/model/blocks_3/se/Mean}}]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
0 successful operations. 0 derived errors ignored.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "main.py", line 389, in
[[strided_slice_6/_18487]]
Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
(1) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[node efficientnet-b1/model/blocks_3/se/Mean (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:325) ]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
0 successful operations. 0 derived errors ignored.
Errors may have originated from an input operation. Input Source operations connected to node efficientnet-b1/model/blocks_3/se/Mean: efficientnet-b1/model/blocks_3/IdentityN_1 (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:373)
Input Source operations connected to node efficientnet-b1/model/blocks_3/se/Mean: efficientnet-b1/model/blocks_3/IdentityN_1 (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:373)
Original stack trace for 'efficientnet-b1/model/blocks_3/se/Mean':
File "main.py", line 389, in
老哥我好像遇到OOM的问题了?bs已经是4了,2080ti 8块还是不行
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
python main.py --training_file_pattern=tfrecord/train* --model_name=efficientdet-d3 --model_dir=tmp/model --hparams="use_bfloat16=false, num_classes=6" --use_tpu=False --ckpt=tmp/efficientdet-d3 --validation_file_pattern=tfrecord/val* --val_json_file=tfrecord/annotations/val2017.json --mode='train_and_eval' --logdir=logs
这是我的训练命令 --model_dir=tmp/model 这个是我新建的一个文件夹 训练过程中 会把训练的模型存放在这个文件夹下面 而且我查看了其他人的训练命令 几乎都是这样的
2020-04-01 13:06:02.697149: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0374e00 of size 256 next 3439 2020-04-01 13:06:02.697431: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0374f00 of size 256 next 3440
2020-04-01 13:06:02.704638: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376c00 of size 256 next 3469 2020-04-01 13:06:02.704904: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376d00 of size 256 next 3470 2020-04-01 13:06:02.705134: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376e00 of size 256 next 3471 2020-04-01 13:06:02.705401: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0376f00 of size 256 next 3472 2020-04-01 13:06:02.705683: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377000 of size 256 next 3473 2020-04-01 13:06:02.705937: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377100 of size 256 next 3474 2020-04-01 13:06:02.706170: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377200 of size 256 next 3475 2020-04-01 13:06:02.706446: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377300 of size 256 next 3476 2020-04-01 13:06:02.706662: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377400 of size 256 next 3477 2020-04-01 13:06:02.706964: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377500 of size 256 next 3478 2020-04-01 13:06:02.707195: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377600 of size 256 next 3479 2020-04-01 13:06:02.707448: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377700 of size 256 next 3480 2020-04-01 13:06:02.707703: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377800 of size 256 next 3481 2020-04-01 13:06:02.707978: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377900 of size 256 next 3482 2020-04-01 13:06:02.708240: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377a00 of size 256 next 3483 2020-04-01 13:06:02.708466: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377b00 of size 256 next 3484 2020-04-01 13:06:02.708658: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377c00 of size 256 next 3485 2020-04-01 13:06:02.708863: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377d00 of size 256 next 3486 2020-04-01 13:06:02.709047: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377e00 of size 256 next 3487 2020-04-01 13:06:02.709219: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0377f00 of size 256 next 3488 2020-04-01 13:06:02.709371: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378000 of size 256 next 3489 2020-04-01 13:06:02.709541: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378100 of size 256 next 3490 2020-04-01 13:06:02.709745: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378200 of size 256 next 3491 2020-04-01 13:06:02.709904: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378300 of size 256 next 3492 2020-04-01 13:06:02.710073: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378400 of size 256 next 3493 2020-04-01 13:06:02.710259: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378500 of size 256 next 3494 2020-04-01 13:06:02.710439: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378600 of size 256 next 3495 2020-04-01 13:06:02.710608: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378700 of size 256 next 3496 2020-04-01 13:06:02.710867: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378800 of size 256 next 3497 2020-04-01 13:06:02.711020: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378900 of size 256 next 3498 2020-04-01 13:06:02.711183: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378a00 of size 256 next 3499 2020-04-01 13:06:02.711361: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378b00 of size 256 next 3500 2020-04-01 13:06:02.711547: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378c00 of size 256 next 3501 2020-04-01 13:06:02.711731: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378d00 of size 256 next 3502 2020-04-01 13:06:02.712008: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378e00 of size 256 next 3503 2020-04-01 13:06:02.712294: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0378f00 of size 256 next 3504 2020-04-01 13:06:02.712563: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379000 of size 256 next 3505 2020-04-01 13:06:02.712888: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379100 of size 256 next 3506 2020-04-01 13:06:02.713179: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379200 of size 256 next 3507 2020-04-01 13:06:02.713436: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379300 of size 256 next 3508 2020-04-01 13:06:02.713685: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379400 of size 256 next 3509 2020-04-01 13:06:02.713907: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379500 of size 256 next 3510 2020-04-01 13:06:02.714102: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379600 of size 256 next 3511 2020-04-01 13:06:02.714287: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379700 of size 256 next 3512 2020-04-01 13:06:02.714443: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379800 of size 256 next 3513 2020-04-01 13:06:02.714592: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379900 of size 256 next 3514 2020-04-01 13:06:02.714902: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379a00 of size 256 next 3515 2020-04-01 13:06:02.715128: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379b00 of size 256 next 3516 2020-04-01 13:06:02.715363: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379c00 of size 256 next 3517 2020-04-01 13:06:02.715690: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379d00 of size 256 next 3518 2020-04-01 13:06:02.715873: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379e00 of size 256 next 3519 2020-04-01 13:06:02.716036: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e0379f00 of size 256 next 3520 2020-04-01 13:06:02.716230: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a000 of size 256 next 3521 2020-04-01 13:06:02.716421: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a100 of size 256 next 3522 2020-04-01 13:06:02.716592: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a200 of size 256 next 3523 2020-04-01 13:06:02.716856: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a300 of size 256 next 3524 2020-04-01 13:06:02.717047: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a400 of size 256 next 3525 2020-04-01 13:06:02.717221: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a500 of size 256 next 3526 2020-04-01 13:06:02.717412: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a600 of size 256 next 3527 2020-04-01 13:06:02.717557: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a700 of size 256 next 3528 2020-04-01 13:06:02.717741: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a800 of size 256 next 3529 2020-04-01 13:06:02.718013: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b34e037a900 of size 256 next 3530 e/bfc_allocator.cc:950] InUse at 2b3537165b00 of size 157286400 next 4426 2020-04-01 13:06:02.936237: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3540765b00 of size 157286400 next 4427 2020-04-01 13:06:02.936476: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3549d65b00 of size 39321600 next 4428 2020-04-01 13:06:02.936753: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b354c2e5b00 of size 39321600 next 4429 2020-04-01 13:06:02.937002: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b354e865b00 of size 39321600 next 4430 2020-04-01 13:06:02.937259: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3550de5b00 of size 39321600 next 4433 2020-04-01 13:06:02.937580: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3553365b00 of size 9830400 next 4434 2020-04-01 13:06:02.937812: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3553cc5b00 of size 9830400 next 4435 2020-04-01 13:06:02.938022: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3554625b00 of size 58982400 next 4438 2020-04-01 13:06:02.938227: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3557e65b00 of size 58982400 next 4439 2020-04-01 13:06:02.938457: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b355b6a5b00 of size 58982400 next 4440 2020-04-01 13:06:02.938698: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b355eee5b00 of size 58982400 next 4441 2020-04-01 13:06:02.938925: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3562725b00 of size 58982400 next 4442 2020-04-01 13:06:02.939158: I tensorflow/core/common_runtime/bfc_allocator.cc:950] InUse at 2b3565f65b00 of size 82552064 next 18446744073709551615 2020-04-01 13:06:02.939368: I tensorflow/core/common_runtime/bfc_allocator.cc:955] Summary of in-use Chunks by size: 2020-04-01 13:06:02.939599: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 2009 Chunks of size 256 totalling 502.2KiB 2020-04-01 13:06:02.940008: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1086 Chunks of size 512 totalling 543.0KiB 2020-04-01 13:06:02.940298: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 105 Chunks of size 768 totalling 78.8KiB 2020-04-01 13:06:02.940521: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 69 Chunks of size 1024 totalling 69.0KiB 2020-04-01 13:06:02.940767: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 22 Chunks of size 1280 totalling 27.5KiB 2020-04-01 13:06:02.941103: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 1536 totalling 10.5KiB 2020-04-01 13:06:02.941330: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 1792 totalling 1.8KiB 2020-04-01 13:06:02.941593: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 76 Chunks of size 2048 totalling 152.0KiB 2020-04-01 13:06:02.941914: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 2304 totalling 6.8KiB 2020-04-01 13:06:02.942163: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 2560 totalling 2.5KiB 2020-04-01 13:06:02.942429: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 73 Chunks of size 2816 totalling 200.8KiB 2020-04-01 13:06:02.942702: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 204 Chunks of size 3328 totalling 663.0KiB 2020-04-01 13:06:02.942955: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 27 Chunks of size 3584 totalling 94.5KiB 2020-04-01 13:06:02.943260: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 3840 totalling 3.8KiB 2020-04-01 13:06:02.943525: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 4096 totalling 4.0KiB 2020-04-01 13:06:02.943747: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 91 Chunks of size 4608 totalling 409.5KiB 2020-04-01 13:06:02.943998: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 5120 totalling 5.0KiB 2020-04-01 13:06:02.944239: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 5376 totalling 36.8KiB 2020-04-01 13:06:02.944492: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 6144 totalling 24.0KiB 2020-04-01 13:06:02.944706: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 19 Chunks of size 7680 totalling 142.5KiB 2020-04-01 13:06:02.944912: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 8704 totalling 34.0KiB 2020-04-01 13:06:02.945179: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 9216 totalling 36.0KiB 2020-04-01 13:06:02.945398: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 20 Chunks of size 9728 totalling 190.0KiB 2020-04-01 13:06:02.945629: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 12800 totalling 62.5KiB 2020-04-01 13:06:02.945843: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 17 Chunks of size 13824 totalling 229.5KiB 2020-04-01 13:06:02.946058: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 14080 totalling 68.8KiB 2020-04-01 13:06:02.946288: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 14592 totalling 114.0KiB 2020-04-01 13:06:02.946511: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 17408 totalling 170.0KiB 2020-04-01 13:06:02.946790: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 23040 totalling 90.0KiB 2020-04-01 13:06:02.947039: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 7 Chunks of size 24064 totalling 164.5KiB 2020-04-01 13:06:02.947311: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 190 Chunks of size 30976 totalling 5.61MiB 2020-04-01 13:06:02.947528: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 43 Chunks of size 38400 totalling 1.57MiB 2020-04-01 13:06:02.947732: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 39424 totalling 385.0KiB 2020-04-01 13:06:02.947964: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 41472 totalling 162.0KiB 2020-04-01 13:06:02.948171: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 48128 totalling 188.0KiB 2020-04-01 13:06:02.948397: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 57600 totalling 225.0KiB 2020-04-01 13:06:02.948687: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 13 Chunks of size 67328 totalling 854.8KiB 2020-04-01 13:06:02.948929: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 69120 totalling 270.0KiB 2020-04-01 13:06:02.949151: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 26 Chunks of size 75264 totalling 1.87MiB 2020-04-01 13:06:02.949365: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 76800 totalling 300.0KiB 2020-04-01 13:06:02.949637: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 81152 totalling 79.2KiB 2020-04-01 13:06:02.949849: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 15 Chunks of size 112640 totalling 1.61MiB 2020-04-01 13:06:02.950106: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 13 Chunks of size 115200 totalling 1.43MiB 2020-04-01 13:06:02.950303: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 23 Chunks of size 153600 totalling 3.37MiB 2020-04-01 13:06:02.950550: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 215040 totalling 840.0KiB 2020-04-01 13:06:02.950784: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 32 Chunks of size 221184 totalling 6.75MiB 2020-04-01 13:06:02.951130: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 230400 totalling 900.0KiB 2020-04-01 13:06:02.951518: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 285184 totalling 1.36MiB 2020-04-01 13:06:02.951749: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 23 Chunks of size 301056 totalling 6.60MiB 2020-04-01 13:06:02.951973: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 324096 totalling 1.85MiB 2020-04-01 13:06:02.952190: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 516096 totalling 1.97MiB 2020-04-01 13:06:02.952484: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 614400 totalling 4.69MiB 2020-04-01 13:06:02.952703: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 29 Chunks of size 884736 totalling 24.47MiB 2020-04-01 13:06:02.952936: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 921600 totalling 3.52MiB 2020-04-01 13:06:02.953181: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 1296128 totalling 7.42MiB 2020-04-01 13:06:02.953483: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 1474560 totalling 5.62MiB 2020-04-01 13:06:02.953705: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 8 Chunks of size 2457600 totalling 18.75MiB 2020-04-01 13:06:02.953915: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 3686400 totalling 10.55MiB 2020-04-01 13:06:02.954200: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 5184000 totalling 29.66MiB 2020-04-01 13:06:02.954427: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 2 Chunks of size 9830400 totalling 18.75MiB 2020-04-01 13:06:02.954670: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 19660800 totalling 18.75MiB 2020-04-01 13:06:02.954945: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 20736000 totalling 118.65MiB 2020-04-01 13:06:02.955140: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 10 Chunks of size 26214400 totalling 250.00MiB 2020-04-01 13:06:02.955388: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 4 Chunks of size 39321600 totalling 150.00MiB 2020-04-01 13:06:02.955650: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 6 Chunks of size 52428800 totalling 300.00MiB 2020-04-01 13:06:02.955888: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 58982400 totalling 281.25MiB 2020-04-01 13:06:02.956125: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 80209664 totalling 76.49MiB 2020-04-01 13:06:02.956371: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 1 Chunks of size 82552064 totalling 78.73MiB 2020-04-01 13:06:02.956600: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 5 Chunks of size 82944000 totalling 395.51MiB 2020-04-01 13:06:02.956887: I tensorflow/core/common_runtime/bfc_allocator.cc:958] 3 Chunks of size 157286400 totalling 450.00MiB 2020-04-01 13:06:02.957131: I tensorflow/core/common_runtime/bfc_allocator.cc:962] Sum Total of in-use chunks: 2.23GiB 2020-04-01 13:06:02.957352: I tensorflow/core/common_runtime/bfc_allocator.cc:964] total_region_allocated_bytes_: 2397175808 memory_limit_: 2397175808 available bytes: 0 curr_region_allocation_bytes_: 4794351616 2020-04-01 13:06:02.957592: I tensorflow/core/common_runtime/bfc_allocator.cc:970] Stats: Limit: 2397175808 InUse: 2395943424 MaxInUse: 2395943424 NumAllocs: 4868 MaxAllocSize: 157286400
2020-04-01 13:06:02.958580: W tensorflow/core/common_runtime/bfc_allocator.cc:429] x***************************************************** 2020-04-01 13:06:02.960895: W tensorflow/core/framework/op_kernel.cc:1655] OP_REQUIRES failed at reduction_gpu_kernels.cu.h:917 : Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc INFO:tensorflow:training_loop marked as finished I0401 13:06:14.966216 47484351229632 error_handling.py:108] training_loop marked as finished WARNING:tensorflow:Reraising captured error W0401 13:06:14.983711 47484351229632 error_handling.py:142] Reraising captured error Traceback (most recent call last): File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1367, in _do_call return fn(*args) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1352, in _run_fn target_list, run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1445, in _call_tf_sessionrun run_metadata) tensorflow.python.framework.errors_impl.ResourceExhaustedError: 2 root error(s) found. (0) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[{{node efficientnet-b1/model/blocks_3/se/Mean}}]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
[[strided_slice_6/_18487]]Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
(1) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[{{node efficientnet-b1/model/blocks_3/se/Mean}}]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
0 successful operations. 0 derived errors ignored.
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "main.py", line 389, in tf.app.run(main) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/platform/app.py", line 40, in run _run(main=main, argv=argv, flags_parser=_parse_flags_tolerate_undef) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/absl/app.py", line 299, in run _run_main(main, args) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/absl/app.py", line 250, in _run_main sys.exit(main(argv)) File "main.py", line 254, in main FLAGS.train_batch_size)) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 3035, in train rendezvous.raise_errors() File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/error_handling.py", line 143, in raise_errors six.reraise(typ, value, traceback) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/six.py", line 703, in reraise raise value File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 3030, in train saving_listeners=saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 374, in train loss = self._train_model(input_fn, hooks, saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1164, in _train_model return self._train_model_default(input_fn, hooks, saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1198, in _train_model_default saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1497, in _train_with_estimator_spec _, loss = mon_sess.run([estimator_spec.train_op, estimator_spec.loss]) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 778, in run run_metadata=run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 1283, in run run_metadata=run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 1384, in run raise six.reraise(*original_exc_info) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/six.py", line 703, in reraise raise value File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 1369, in run return self._sess.run(*args, **kwargs) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 1442, in run run_metadata=run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/training/monitored_session.py", line 1200, in run return self._sess.run(*args, **kwargs) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 960, in run run_metadata_ptr) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1183, in _run feed_dict_tensor, options, run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1361, in _do_run run_metadata) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1386, in _do_call raise type(e)(node_def, op, message) tensorflow.python.framework.errors_impl.ResourceExhaustedError: 2 root error(s) found. (0) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[node efficientnet-b1/model/blocks_3/se/Mean (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:325) ]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
[[strided_slice_6/_18487]]Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
(1) Resource exhausted: OOM when allocating tensor with shape[3932928] and type int8 on /job:localhost/replica:0/task:0/device:GPU:0 by allocator GPU_0_bfc [[node efficientnet-b1/model/blocks_3/se/Mean (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:325) ]] Hint: If you want to see a list of allocated tensors when OOM happens, add report_tensor_allocations_upon_oom to RunOptions for current allocation info.
0 successful operations. 0 derived errors ignored.
Errors may have originated from an input operation. Input Source operations connected to node efficientnet-b1/model/blocks_3/se/Mean: efficientnet-b1/model/blocks_3/IdentityN_1 (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:373)
Input Source operations connected to node efficientnet-b1/model/blocks_3/se/Mean: efficientnet-b1/model/blocks_3/IdentityN_1 (defined at /cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py:373)
Original stack trace for 'efficientnet-b1/model/blocks_3/se/Mean': File "main.py", line 389, in tf.app.run(main) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/platform/app.py", line 40, in run _run(main=main, argv=argv, flags_parser=_parse_flags_tolerate_undef) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/absl/app.py", line 299, in run _run_main(main, args) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/absl/app.py", line 250, in _run_main sys.exit(main(argv)) File "main.py", line 254, in main FLAGS.train_batch_size)) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 3030, in train saving_listeners=saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 374, in train loss = self._train_model(input_fn, hooks, saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1164, in _train_model return self._train_model_default(input_fn, hooks, saving_listeners) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1194, in _train_model_default features, labels, ModeKeys.TRAIN, self.config) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 2857, in _call_model_fn config) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/estimator.py", line 1152, in _call_model_fn model_fn_results = self._model_fn(features=features, **kwargs) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 3126, in _model_fn features, labels, is_export_mode=is_export_mode) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 1663, in call_without_tpu return self._call_model_fn(features, labels, is_export_mode=is_export_mode) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/tpu/tpu_estimator.py", line 1994, in _call_model_fn estimator_spec = self._model_fn(features=features, **kwargs) File "/cluster/home/qiaotianwei/automl/efficientdet/det_model_fn.py", line 609, in efficientdet_model_fn model=efficientdet_arch.efficientdet) File "/cluster/home/qiaotianwei/automl/efficientdet/det_model_fn.py", line 412, in _model_fn cls_outputs, box_outputs = _model_outputs() File "/cluster/home/qiaotianwei/automl/efficientdet/det_model_fn.py", line 402, in _model_outputs return model(features, config=hparams_config.Config(params)) File "/cluster/home/qiaotianwei/automl/efficientdet/efficientdet_arch.py", line 551, in efficientdet features = build_backbone(features, config) File "/cluster/home/qiaotianwei/automl/efficientdet/efficientdet_arch.py", line 329, in build_backbone override_params=override_params) File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_builder.py", line 324, in build_model_base features = model(images, training=training, features_only=True) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/keras/engine/base_layer.py", line 778, in call outputs = call_fn(cast_inputs, *args, **kwargs) File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 643, in call for idx, block in enumerate(self._blocks): File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 339, in for_stmt return py_for_stmt(iter, extra_test, body, get_state, set_state, init_vars) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 350, in _py_for_stmt state = body(target, *state) File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 662, in call outputs = block.call( File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 376, in call if self._has_se: File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 920, in if_stmt return _py_if_stmt(cond, body, orelse) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 1029, in _py_if_stmt return body() if cond else orelse() File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 378, in call x = self._call_se(x) File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 315, in _call_se if self._local_pooling: File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 920, in if_stmt return _py_if_stmt(cond, body, orelse) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/autograph/operators/control_flow.py", line 1029, in _py_if_stmt return body() if cond else orelse() File "/cluster/home/qiaotianwei/automl/efficientdet/backbone/efficientnet_model.py", line 325, in _call_se se_tensor = tf.reduce_mean( File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/ops/math_ops.py", line 1854, in reduce_mean_v1 return reduce_mean(input_tensor, axis, keepdims, name) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/util/dispatch.py", line 180, in wrapper return target(*args, **kwargs) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/ops/math_ops.py", line 1912, in reduce_mean name=name)) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/ops/gen_math_ops.py", line 5852, in mean name=name) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/framework/op_def_library.py", line 742, in _apply_op_helper attrs=attr_protos, op_def=op_def) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/framework/ops.py", line 3322, in _create_op_internal op_def=op_def) File "/cluster/home/qiaotianwei/.conda/envs/TF2-gpu/lib/python3.7/site-packages/tensorflow_core/python/framework/ops.py", line 1756, in init self._traceback = tf_stack.extract_stack()
老哥我好像遇到OOM的问题了?bs已经是4了,2080ti 8块还是不行
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980*1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是19801860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980_1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280_760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
因为我最早的时候在yolov3上测试过 我使用19801860的图片 bs只能设置32以下,但是当我使用640640 bs就可以达到128,所以我以为数据集的大小与多少跟gup显存有着直接的关系 或者你把bs设置为1试一试 我目前设置bs 4 4000张图片 训练是没问题 但是就是不能加上eval 否则就会报错
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980_1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280_760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
因为我最早的时候在yolov3上测试过 我使用1980_1860的图片 bs只能设置32以下,但是当我使用640_640 bs就可以达到128,所以我以为数据集的大小与多少跟gup显存有着直接的关系 或者你把bs设置为1试一试 我目前设置bs 4 4000张图片 训练是没问题 但是就是不能加上eval 否则就会报错
老哥还有一个问题就是,我设置的那个args明确了用哪几块gpu,但是还是自动使用了全部的gpu,还没有找到解决办法 CUDA_VISIBLE_DEVICE=5, 6
CUDA_VISIBLE_DEVICE=5, 6 python main.py --training_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/train.tfrecord --model_name=efficientdet-d1 --ckpt=/cluster/home/qiaotianwei/automl/efficientdet/efficientdet-d1 --hparams="use_bfloat16=false" --use_tpu=False --train_batch_size 4 --model_dir=/tmp/efficientdet/efficientdet-d1 --mode='train' --validation_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/val.tfrecord
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980_1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280_760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
因为我最早的时候在yolov3上测试过 我使用1980_1860的图片 bs只能设置32以下,但是当我使用640_640 bs就可以达到128,所以我以为数据集的大小与多少跟gup显存有着直接的关系 或者你把bs设置为1试一试 我目前设置bs 4 4000张图片 训练是没问题 但是就是不能加上eval 否则就会报错
老哥还有一个问题就是,我设置的那个args明确了用哪几块gpu,但是还是自动使用了全部的gpu,还没有找到解决办法
CUDA_VISIBLE_DEVICE=5, 6CUDA_VISIBLE_DEVICE=5, 6 python main.py --training_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/train.tfrecord --model_name=efficientdet-d1 --ckpt=/cluster/home/qiaotianwei/automl/efficientdet/efficientdet-d1 --hparams="use_bfloat16=false" --use_tpu=False --train_batch_size 4 --model_dir=/tmp/efficientdet/efficientdet-d1 --mode='train' --validation_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/val.tfrecord
这个我就无能为力拉 我只有一块卡 哈哈 所以我也不知道怎么办
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980_1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280_760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
因为我最早的时候在yolov3上测试过 我使用1980_1860的图片 bs只能设置32以下,但是当我使用640_640 bs就可以达到128,所以我以为数据集的大小与多少跟gup显存有着直接的关系 或者你把bs设置为1试一试 我目前设置bs 4 4000张图片 训练是没问题 但是就是不能加上eval 否则就会报错
老哥还有一个问题就是,我设置的那个args明确了用哪几块gpu,但是还是自动使用了全部的gpu,还没有找到解决办法
CUDA_VISIBLE_DEVICE=5, 6CUDA_VISIBLE_DEVICE=5, 6 python main.py --training_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/train.tfrecord --model_name=efficientdet-d1 --ckpt=/cluster/home/qiaotianwei/automl/efficientdet/efficientdet-d1 --hparams="use_bfloat16=false" --use_tpu=False --train_batch_size 4 --model_dir=/tmp/efficientdet/efficientdet-d1 --mode='train' --validation_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/val.tfrecord这个我就无能为力拉 我只有一块卡 哈哈 所以我也不知道怎么办
老哥,我刚砍了一部分数据集,训练的时候需要args里加上validation吗?
@qtw1998 并不是 --model_dir 这个是用于存放你训练后保存模型的地址.
这个我也不太清楚 我觉得这个模型训练特别占显存 我是titan RTX 24g 数据集大概4000张 像素是1980_1860 bs也是只能设置4 大一点也会oom 在yolov3里可以设置到32 很奇怪 你可以减少一些数据集 测试一下 ———————————————————————————————— 老哥那就有意思了,我的数据集70000张图片1280_760, bs = 4 oom, 但是不是和bs每次读进去的有关吗?减少数据集起作用吗?很困惑
因为我最早的时候在yolov3上测试过 我使用1980_1860的图片 bs只能设置32以下,但是当我使用640_640 bs就可以达到128,所以我以为数据集的大小与多少跟gup显存有着直接的关系 或者你把bs设置为1试一试 我目前设置bs 4 4000张图片 训练是没问题 但是就是不能加上eval 否则就会报错
老哥还有一个问题就是,我设置的那个args明确了用哪几块gpu,但是还是自动使用了全部的gpu,还没有找到解决办法
CUDA_VISIBLE_DEVICE=5, 6CUDA_VISIBLE_DEVICE=5, 6 python main.py --training_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/train.tfrecord --model_name=efficientdet-d1 --ckpt=/cluster/home/qiaotianwei/automl/efficientdet/efficientdet-d1 --hparams="use_bfloat16=false" --use_tpu=False --train_batch_size 4 --model_dir=/tmp/efficientdet/efficientdet-d1 --mode='train' --validation_file_pattern=/cluster/home/qiaotianwei/automl/bdd100k/val.tfrecord这个我就无能为力拉 我只有一块卡 哈哈 所以我也不知道怎么办
老哥,我刚砍了一部分数据集,训练的时候需要args里加上validation吗?
你先不加吧 先看看训练能否跑通 加上了 有可能出现其他问题 我就是加上了后 出现pycocotools 与python3不兼容 和 numpy 版本太高 报错
You need to download the latest Pretrained EfficientDet Checkpoints, https://storage.googleapis.com/cloud-tpu-checkpoints/efficientdet/coco/efficientdet-d0.tar.gz and then use -- ckpt= to specify it
原来是国人哈哈 我都没注意名字 大佬你模型跑通了吗?我用训练好的的模型(2类)运行inference.py,想测试一下效果但是我报错了
INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300
INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300
InvalidArgumentError Traceback (most recent call last)
/usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args)
1364 try:
-> 1365 return fn(*args)
1366 except errors.OpError as e:
7 frames
InvalidArgumentError: 2 root error(s) found.
(0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
[[{{node Reshape}}]]
[[strided_slice_8/_2717]]
(1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
[[{{node Reshape}}]]
0 successful operations.
0 derived errors ignored.
During handling of the above exception, another exception occurred:
InvalidArgumentError Traceback (most recent call last)
/usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args)
1382 '\nsession_config.graph_options.rewrite_options.'
1383 'disable_meta_optimizer = True')
-> 1384 raise type(e)(node_def, op, message)
1385
1386 def _extend_graph(self):
InvalidArgumentError: 2 root error(s) found.
(0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
[[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]]
[[strided_slice_8/_2717]]
(1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
[[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]]
0 successful operations.
0 derived errors ignored.
Errors may have originated from an input operation.
Input Source operations connected to node Reshape:
class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202)
Input Source operations connected to node Reshape:
class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202)
Original stack trace for 'Reshape':
File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "/usr/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/usr/local/lib/python3.6/dist-packages/ipykernel_launcher.py", line 16, in
app.launch_new_instance()
File "/usr/local/lib/python3.6/dist-packages/traitlets/config/application.py", line 664, in launch_instance
app.start()
File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelapp.py", line 477, in start
ioloop.IOLoop.instance().start()
File "/usr/local/lib/python3.6/dist-packages/tornado/ioloop.py", line 888, in start
handler_func(fd_obj, events)
File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper
return fn(*args, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 450, in _handle_events
self._handle_recv()
File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 480, in _handle_recv
self._run_callback(callback, msg)
File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 432, in _run_callback
callback(*args, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper
return fn(*args, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 283, in dispatcher
return self.dispatch_shell(stream, msg)
File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell
handler(stream, idents, msg)
File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 399, in execute_request
user_expressions, allow_stdin)
File "/usr/local/lib/python3.6/dist-packages/ipykernel/ipkernel.py", line 196, in do_execute
res = shell.run_cell(code, store_history=store_history, silent=silent)
File "/usr/local/lib/python3.6/dist-packages/ipykernel/zmqshell.py", line 533, in run_cell
return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2718, in run_cell
interactivity=interactivity, compiler=compiler, result=result)
File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2828, in run_ast_nodes
if self.run_code(code, result):
File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2882, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "", line 18, in
line_thickness=line_thickness)
File "/content/drive/My Drive/automl/efficientdet/inference.py", line 529, in inference
box_outputs,
File "/content/drive/My Drive/automl/efficientdet/inference.py", line 179, in det_post_process
'indices_all': [None],
File "/content/drive/My Drive/automl/efficientdet/det_model_fn.py", line 293, in add_metric_fn_inputs
[params['batch_size'], -1, params['num_classes']]))
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/array_ops.py", line 193, in reshape
result = gen_array_ops.reshape(tensor, shape, name)
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/gen_array_ops.py", line 8087, in reshape
"Reshape", tensor=tensor, shape=shape, name=name)
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/op_def_library.py", line 744, in _apply_op_helper
attrs=attr_protos, op_def=op_def)
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 3327, in _create_op_internal
op_def=op_def)
File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 1791, in init
self._traceback = tf_stack.extract_stack()
我把 hparams_config.py 里的num_classes设置成2也没用 还是有错误Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
您需要下载最新的Pretrained EfficientDet检查点,https ://storage.googleapis.com/cloud-tpu-checkpoints/ficientdet/coco/ficientdet-d0.tar.gz,然后使用-ckpt =进行指定
原来是国人哈哈我都没注意名字 大佬你模型跑通了吗?我用训练好的的模型(2类)运行inference.py,想测试一下效果但是我报错了
INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300 INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300 InvalidArgumentError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args) 1364 try: -> 1365 return fn(*args) 1366 except errors.OpError as e: 7 frames InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[{{node Reshape}}]] [[strided_slice_8/_2717]] (1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[{{node Reshape}}]] 0 successful operations. 0 derived errors ignored. During handling of the above exception, another exception occurred: InvalidArgumentError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args) 1382 '\nsession_config.graph_options.rewrite_options.' 1383 'disable_meta_optimizer = True') -> 1384 raise type(e)(node_def, op, message) 1385 1386 def _extend_graph(self): InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]] [[strided_slice_8/_2717]] (1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]] 0 successful operations. 0 derived errors ignored. Errors may have originated from an input operation. Input Source operations connected to node Reshape: class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202) Input Source operations connected to node Reshape: class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202) Original stack trace for 'Reshape': File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main "main", mod_spec) File "/usr/lib/python3.6/runpy.py", line 85, in _run_code exec(code, run_globals) File "/usr/local/lib/python3.6/dist-packages/ipykernel_launcher.py", line 16, in app.launch_new_instance() File "/usr/local/lib/python3.6/dist-packages/traitlets/config/application.py", line 664, in launch_instance app.start() File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelapp.py", line 477, in start ioloop.IOLoop.instance().start() File "/usr/local/lib/python3.6/dist-packages/tornado/ioloop.py", line 888, in start handler_func(fd_obj, events) File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper return fn(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 450, in _handle_events self._handle_recv() File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 480, in _handle_recv self._run_callback(callback, msg) File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 432, in _run_callback callback(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper return fn(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 283, in dispatcher return self.dispatch_shell(stream, msg) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell handler(stream, idents, msg) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 399, in execute_request user_expressions, allow_stdin) File "/usr/local/lib/python3.6/dist-packages/ipykernel/ipkernel.py", line 196, in do_execute res = shell.run_cell(code, store_history=store_history, silent=silent) File "/usr/local/lib/python3.6/dist-packages/ipykernel/zmqshell.py", line 533, in run_cell return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2718, in run_cell interactivity=interactivity, compiler=compiler, result=result) File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2828, in run_ast_nodes if self.run_code(code, result): File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2882, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 18, in line_thickness=line_thickness) File "/content/drive/My Drive/automl/efficientdet/inference.py", line 529, in inference box_outputs, File "/content/drive/My Drive/automl/efficientdet/inference.py", line 179, in det_post_process 'indices_all': [None], File "/content/drive/My Drive/automl/efficientdet/det_model_fn.py", line 293, in add_metric_fn_inputs [params['batch_size'], -1, params['num_classes']])) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/array_ops.py", line 193, in reshape result = gen_array_ops.reshape(tensor, shape, name) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/gen_array_ops.py", line 8087, in reshape "Reshape", tensor=tensor, shape=shape, name=name) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/op_def_library.py", line 744, in _apply_op_helper attrs=attr_protos, op_def=op_def) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 3327, in _create_op_internal op_def=op_def) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 1791, in init self._traceback = tf_stack.extract_stack()我把
hparams_config.py里的num_classes设置成2也没用还是有错误Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90
推理代码是 model_inference.py
这是我的推理命令
python model_inspect.py --runmode=infer --model_name=efficientdet-d1 --ckpt_path=tmp/models_0/ --input_image=test_img/00001.jpg --output_image_dir=val_img
inference.py 这个里面有 coco_id_mapping这个参数, 应该是也决定了以多少类进行推理 ,并且我把这个参数, 按照当时转换数据集的id顺序来设定 推理没有出现报错 。但是问题是 ,我的推理没有画框 ,可能是学习没有到位。我的训练模型已经跑通了 还需要时间来查看效果
您需要下载最新的Pretrained EfficientDet检查点,https ://storage.googleapis.com/cloud-tpu-checkpoints/ficientdet/coco/ficientdet-d0.tar.gz,然后使用-ckpt =进行指定
原来是国人哈哈我都没注意名字 大佬你模型跑通了吗?我用训练好的的模型(2类)运行inference.py,想测试一下效果但是我报错了
INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300 INFO:tensorflow:Restoring parameters from /content/drive/My Drive/automl/efficientdet/trained_model/model.ckpt-300 InvalidArgumentError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args) 1364 try: -> 1365 return fn(*args) 1366 except errors.OpError as e: 7 frames InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[{{node Reshape}}]] [[strided_slice_8/_2717]] (1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[{{node Reshape}}]] 0 successful operations. 0 derived errors ignored. During handling of the above exception, another exception occurred: InvalidArgumentError Traceback (most recent call last) /usr/local/lib/python3.6/dist-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args) 1382 '\nsession_config.graph_options.rewrite_options.' 1383 'disable_meta_optimizer = True') -> 1384 raise type(e)(node_def, op, message) 1385 1386 def _extend_graph(self): InvalidArgumentError: 2 root error(s) found. (0) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]] [[strided_slice_8/_2717]] (1) Invalid argument: Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90 [[node Reshape (defined at /content/drive/My Drive/automl/efficientdet/det_model_fn.py:293) ]] 0 successful operations. 0 derived errors ignored. Errors may have originated from an input operation. Input Source operations connected to node Reshape: class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202) Input Source operations connected to node Reshape: class_net/class-predict/BiasAdd (defined at /content/drive/My Drive/automl/efficientdet/efficientdet_arch.py:202) Original stack trace for 'Reshape': File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main "main", mod_spec) File "/usr/lib/python3.6/runpy.py", line 85, in _run_code exec(code, run_globals) File "/usr/local/lib/python3.6/dist-packages/ipykernel_launcher.py", line 16, in app.launch_new_instance() File "/usr/local/lib/python3.6/dist-packages/traitlets/config/application.py", line 664, in launch_instance app.start() File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelapp.py", line 477, in start ioloop.IOLoop.instance().start() File "/usr/local/lib/python3.6/dist-packages/tornado/ioloop.py", line 888, in start handler_func(fd_obj, events) File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper return fn(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 450, in _handle_events self._handle_recv() File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 480, in _handle_recv self._run_callback(callback, msg) File "/usr/local/lib/python3.6/dist-packages/zmq/eventloop/zmqstream.py", line 432, in _run_callback callback(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/tornado/stack_context.py", line 277, in null_wrapper return fn(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 283, in dispatcher return self.dispatch_shell(stream, msg) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell handler(stream, idents, msg) File "/usr/local/lib/python3.6/dist-packages/ipykernel/kernelbase.py", line 399, in execute_request user_expressions, allow_stdin) File "/usr/local/lib/python3.6/dist-packages/ipykernel/ipkernel.py", line 196, in do_execute res = shell.run_cell(code, store_history=store_history, silent=silent) File "/usr/local/lib/python3.6/dist-packages/ipykernel/zmqshell.py", line 533, in run_cell return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs) File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2718, in run_cell interactivity=interactivity, compiler=compiler, result=result) File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2828, in run_ast_nodes if self.run_code(code, result): File "/usr/local/lib/python3.6/dist-packages/IPython/core/interactiveshell.py", line 2882, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 18, in line_thickness=line_thickness) File "/content/drive/My Drive/automl/efficientdet/inference.py", line 529, in inference box_outputs, File "/content/drive/My Drive/automl/efficientdet/inference.py", line 179, in det_post_process 'indices_all': [None], File "/content/drive/My Drive/automl/efficientdet/det_model_fn.py", line 293, in add_metric_fn_inputs [params['batch_size'], -1, params['num_classes']])) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/array_ops.py", line 193, in reshape result = gen_array_ops.reshape(tensor, shape, name) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/ops/gen_array_ops.py", line 8087, in reshape "Reshape", tensor=tensor, shape=shape, name=name) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/op_def_library.py", line 744, in _apply_op_helper attrs=attr_protos, op_def=op_def) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 3327, in _create_op_internal op_def=op_def) File "/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py", line 1791, in init self._traceback = tf_stack.extract_stack()我把
hparams_config.py里的num_classes设置成2也没用还是有错误Input to reshape is a tensor with 373248 values, but the requested shape requires a multiple of 90推理代码是 model_inference.py
这是我的推理命令
python model_inspect.py --runmode=infer --model_name=efficientdet-d1 --ckpt_path=tmp/models_0/ --input_image=test_img/00001.jpg --output_image_dir=val_img
inference.py 这个里面有 coco_id_mapping这个参数, 应该是也决定了以多少类进行推理 ,并且我把这个参数, 按照当时转换数据集的id顺序来设定 推理没有出现报错 。但是问题是 ,我的推理没有画框 ,可能是学习没有到位。我的训练模型已经跑通了 还需要时间来查看效果
老哥我发现我的BDD100K(10类)不能用pre-trained ckpt(80 coco)我是不是得从头训练?或者怎改ckpt的输出?