title: "tensorflow.python.framework.errors_impl.FailedPreconditionError: =; Is a directory"getting error running model_main.py
body: <p>I ran the command:</p>
  
  <pre><code>python3 research/object_detection/legacy/train.py \
      --logtostderr \
      --train_dir = training/ \
      --pipeline_config_path = training/ssd_mobilenet_v1_pets.config
  </code></pre>
  
  <p>but I am getting this error:</p>
  
  <pre><code>WARNING: The TensorFlow contrib module will not be included in TensorFlow 2.0.
  For more information, please see:
    * https://github.com/tensorflow/community/blob/master/rfcs/20180907-contrib-sunset.md
    * https://github.com/tensorflow/addons
  If you depend on functionality not listed there, please file an issue.
  WARNING:tensorflow:From /home/apoorva/.local/lib/python3.5/site-packages/tensorflow/python/platform/app.py:125: main (from __main__) is deprecated and will be removed in a future version.
  Instructions for updating:
  Use object_detection/model_main.py.
  Traceback (most recent call last):
    File "research/object_detection/legacy/train.py", line 184, in &lt;module&gt;
      tf.app.run()
    File "/home/apoorva/.local/lib/python3.5/site-packages/tensorflow/python/platform/app.py", line 125, in run
      _sys.exit(main(argv))
    File "/home/apoorva/.local/lib/python3.5/site-packages/tensorflow/python/util/deprecation.py", line 324, in new_func
      return func(*args, **kwargs)
    File "research/object_detection/legacy/train.py", line 93, in main
      FLAGS.pipeline_config_path)
    File "/home/apoorva/Tensorflowapi/models-master/research/slim/object_detection/utils/config_util.py", line 97, in get_configs_from_pipeline_file
      proto_str = f.read()
    File "/home/apoorva/.local/lib/python3.5/site-packages/tensorflow/python/lib/io/file_io.py", line 132, in read
      pywrap_tensorflow.ReadFromStream(self._read_buf, length, status))
    File "/home/apoorva/.local/lib/python3.5/site-packages/tensorflow/python/framework/errors_impl.py", line 528, in __exit__
      c_api.TF_GetCode(self.status.status))
  tensorflow.python.framework.errors_impl.FailedPreconditionError: =; Is a directory
  </code></pre>
  
  <p>I ran <code>train.py</code> in <code>models/research/object_detection/legacy</code>, got the same error so tried to run <code>model_main.py</code> which is the later version of <code>train.py</code> but still unable to solve the problem.</p>
  
  <pre><code>python3 research/object_detection/legacy/train.py \
      --logtostderr \
      --train_dir = training/ \
      --pipeline_config_path = training/ssd_mobilenet_v1_pets.config
  </code></pre>
  
  <p>I expected training to start and showing losses and accuracy at each step but the command isn't running.</p>