SaoYan / bgsCNN

Background subtraction using deep learning method.
GNU General Public License v3.0
191 stars 61 forks source link

AssertionError:assert os.path.isdir(some_dir) #4

Closed QianyuanLiu closed 3 years ago

QianyuanLiu commented 6 years ago

hello, SaoYan I already have downloadedthe dataset your provided(BaiduNetdisk) and had the TFrecords files. when I typed “python train.py --prepare_data False --train_file train.tfrecords --test_file test.tfrecords --log_dir logs --model_version 2 --image_height 321 --image_width 321 --train_batch_size 40 --test_batch_size 200 --max_iteration 10000” An AssertionError is raised: `rosfun@ubuntu:~/docment/bgsCNN$ python train.py --prepare_data False --train_file train.tfrecords --test_file test.tfrecords --log_dir logs --model_version 2 --image_height 321 --image_width 321 --train_batch_size 40 --test_batch_size 200 --max_iteration 10000 PYTHON TYPE CONVERTERS exported Traceback (most recent call last): File "train.py", line 83, in tf.app.run() File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 133, in run _sys.exit(main(argv)) File "train.py", line 34, in main prepare_data(FLAGS.dataset_dir, FLAGS.image_height, FLAGS.image_width) File "/home/rosfun/docment/bgsCNN/prepare_data.py", line 15, in prepare_data for __, dirnames_l0, __ in walklevel(root_dir, level = 0): File "/home/rosfun/docment/bgsCNN/utilities.py", line 119, in walklevel assert os.path.isdir(some_dir) AssertionError

` my Tf_version is 1.4 . how cloud I fix this issue ? thanks !

SaoYan commented 6 years ago

Make sure this option is correct: "prepare_data --False".

TMTING commented 6 years ago

hi, i don't know how to download tfrecords , could you please give a link for me ?

SaoYan commented 6 years ago

The tfrecords files are too large to upload (or download). I recommend that you download the pre-processed dataset and generate tfrecords yourself. You can get pre-processed dataset the from https://drive.google.com/open?id=0BxTycO36H3VARFdRQkR1WHJYM0E or https://pan.baidu.com/s/1qYmcUC0

TMTING commented 6 years ago

Thanks for your applying when I run this prepare_data.py , it can't get tfrecords files . and get two 0 bytes file. I don't know how to deal with it.

SaoYan commented 6 years ago

Make sure you the dataset path is right. You may read and modify the source code yourself if necessary.

TMTING commented 6 years ago

Could I add you as a friend qq or wechat? I have some problems to consult you . my wechat is 15926432279. thanks. @SaoYan

rohit9650 commented 6 years ago

I think you haven't followed the previous step in which we generate the tfrecords , or if you did there might be some error .