我目前正在完成在 Cityscapes 数据集上运行 deeplab 训练 exception_65 主干的步骤,但不幸的是我遇到了分段错误。我无法重现该错误。例如,在 PASCAL 数据集上的训练效果很好。我检查了 tensorflow 和驱动程序的路径和几个版本以及组合等。即使我在没有 GPU 支持的情况下运行 train.py 脚本,我也会遇到相同的分段错误。我在另一台电脑上做了同样的步骤,我工作了。任何人都知道问题是什么?
我的设置:
- Ubuntu 18.04
- NVIDIA RTX 2080 驱动程序版本 430.65(安装了 .run 文件)
- CUDA 10.0(与 .run 文件一起安装)
- cudnn 7.6.5
- 蟒蛇 3.6
- 张量流 1.15
通过运行:
python3 "${WORK_DIR}"/train.py \
--logtostderr \
--training_number_of_steps=${NUM_ITERATIONS} \
--train_split="train_fine" \
--model_variant="xception_65" \
--atrous_rates=6 \
--atrous_rates=12 \
--atrous_rates=18 \
--output_stride=16 \
--decoder_output_stride=4 \
--train_crop_size="769,769" \
--train_batch_size=1 \
--fine_tune_batch_norm=False \
--dataset="cityscapes" \
--tf_initial_checkpoint="${INIT_FOLDER}/deeplabv3_cityscapes_train/model.ckpt" \
--train_logdir="${TRAIN_LOGDIR}" \
--dataset_dir="${CITYSCAPES_DATASET}"
我得到以下输出:
I1119 16:52:49.856512 139832269989696 learning.py:768] Starting Queues.
Fatal Python error: Segmentation fault
Thread 0x00007f2cd086b700 (most recent call first):
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/threading.py", line 296 in wait
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/queue.py", line 170 in get
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/summary/writer/event_file_writer.py", line 159 in run
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/threading.py", line 926 in _bootstrap_inner
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/threading.py", line 890 in _bootstrap
Thread 0x00007f2d3cc7e740 (most recent call first):
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1443 in _call_tf_sessionrun
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1350 in _run_fn
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1365 in _do_call
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1359 in _do_run
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1180 in _run
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 956 in run
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/contrib/slim/python/slim/learning.py", line 490 in train_step
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/contrib/slim/python/slim/learning.py", line 775 in train
File "/home/kuschnig/tensorflow/models/research/deeplab/train.py", line 466 in main
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/absl/app.py", line 250 in _run_main
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/absl/app.py", line 299 in run
File "/home/kuschnig/anaconda3/envs/conda-tf/lib/python3.7/site-packages/tensorflow_core/python/platform/app.py", line 40 in run
File "/home/kuschnig/tensorflow/models/research/deeplab/train.py", line 472 in <module>
Segmentation fault (core dumped)
使用 gdb 的回溯显示: GDB 输出