title: Prediction : Can`t load model "VGG16 model.h5" in system Weights
body: <p><em>load model</em> </p>
  
  <blockquote>
    <p>"<strong>model.load_weights(VGG16(include_top=False, weights='imagenet'))</strong>"</p>
  </blockquote>
  
  <pre><code>
      VGG16=load_model('E:/TBirds/TBirdDOCS/PythonCode/DOCMODEL/vgg16_weights_tf_dim_ordering_tf_kernels_notop.h5')
  
      # build the VGG16 network
      #model = application.VGG16(include_top=False, weights='imagenet')
      model.load_weights(VGG16(include_top=False, weights='imagenet'))
      # get the bottleneck prediction from the pre-trained VGG16 model
      bottleneck_prediction = model.predict(image)
      #print(bottleneck_prediction)
  </code></pre>
  
  <p>ValueError: Cannot create group in read-only mode.</p>
  
  <pre><code>Traceback (most recent call last):
    File "C:/Users/Administrator.SQL6/AppData/Roaming/Python/Python36/site-packages/keras/engine/Auto-AI.py", line 254, in &lt;module&gt;
      main()
    File "C:/Users/Administrator.SQL6/AppData/Roaming/Python/Python36/site-packages/keras/engine/Auto-AI.py", line 244, in main
      prediction_And_Bookmark(writer, Total_Number_of_Pages, pdf_source,File_Name)
    File "C:/Users/Administrator.SQL6/AppData/Roaming/Python/Python36/site-packages/keras/engine/Auto-AI.py", line 189, in prediction_And_Bookmark
      layb, count, pos = predict(test_imag)
    File "C:/Users/Administrator.SQL6/AppData/Roaming/Python/Python36/site-packages/keras/engine/Auto-AI.py", line 97, in predict
      VGG16=load_model('E:/TBirds/TBirdDOCS/PythonCode/DOCMODEL/vgg16_weights_tf_dim_ordering_tf_kernels_notop.h5')
    File "C:\Users\Administrator.SQL6\AppData\Roaming\Python\Python36\site-packages\keras\engine\saving.py", line 492, in load_wrapper
      return load_function(*args, **kwargs)
    File "C:\Users\Administrator.SQL6\AppData\Roaming\Python\Python36\site-packages\keras\engine\saving.py", line 584, in load_model
      model = _deserialize_model(h5dict, custom_objects, compile)
    File "C:\Users\Administrator.SQL6\AppData\Roaming\Python\Python36\site-packages\keras\engine\saving.py", line 270, in _deserialize_model
      model_config = h5dict['model_config']
    File "C:\Users\Administrator.SQL6\AppData\Roaming\Python\Python36\site-packages\keras\utils\io_utils.py", line 318, in __getitem__
      raise ValueError('Cannot create group in read-only mode.')
  ValueError: Cannot create group in read-only mode.
  
  Process finished with exit code 1
  </code></pre>
  
  <blockquote>
    <p>ValueError: Cannot create group in read-only mode.</p>
  </blockquote>