{
  "id": 346173,
  "title": "Loading the picklemodel file for the SALT challenge",
  "url": "/competitions/ai-village-ctf/discussion/346173",
  "author_name": "",
  "post_date": "2022-08-18T07:56:31.767221500Z",
  "votes": 4,
  "comment_count": 3,
  "views": 0,
  "content": "<p>Hi, I don't know if this is part of the puzzle, but I'm having trouble loading the model for the SALT challenge. I can read the picklemodel file using joblib to get a keras model object, but the resulting model doesn't seem to be a full model object. Specifically, I get a</p>\n<p><code>'Model' object has no attribute '_distribution_strategy'</code></p>\n<p>error when trying to make predictions. I'm thinking this might have something to do with different versions of tensorflow/keras being used, but I'm not sure. I'm using tensorflow 2.9.1 and python 3.8.3 if that's any help.</p>",
  "messages": [
    {
      "id": "1904478",
      "postDate": "08/18/2022 07:56:31",
      "content": "<p>Hi, I don't know if this is part of the puzzle, but I'm having trouble loading the model for the SALT challenge. I can read the picklemodel file using joblib to get a keras model object, but the resulting model doesn't seem to be a full model object. Specifically, I get a</p>\n<p><code>'Model' object has no attribute '_distribution_strategy'</code></p>\n<p>error when trying to make predictions. I'm thinking this might have something to do with different versions of tensorflow/keras being used, but I'm not sure. I'm using tensorflow 2.9.1 and python 3.8.3 if that's any help.</p>",
      "rawMarkdown": "Hi, I don't know if this is part of the puzzle, but I'm having trouble loading the model for the SALT challenge. I can read the picklemodel file using joblib to get a keras model object, but the resulting model doesn't seem to be a full model object. Specifically, I get a\n\n`'Model' object has no attribute '_distribution_strategy'`\n\nerror when trying to make predictions. I'm thinking this might have something to do with different versions of tensorflow/keras being used, but I'm not sure. I'm using tensorflow 2.9.1 and python 3.8.3 if that's any help.",
      "votes": null
    },
    {
      "id": "1904780",
      "postDate": "08/18/2022 13:27:03",
      "content": "<p>It’s just an ancient artifact. Maybe from the aliens who built the pyramids. </p>\n<p>tensorflow==1.13.1<br>\nKeras==2.2.4</p>",
      "rawMarkdown": "It’s just an ancient artifact. Maybe from the aliens who built the pyramids. \n\ntensorflow==1.13.1\nKeras==2.2.4",
      "votes": null
    },
    {
      "id": "1905202",
      "postDate": "08/18/2022 20:02:39",
      "content": "<p>Thanks! Using those versions fixed the issue for me.</p>",
      "rawMarkdown": "Thanks! Using those versions fixed the issue for me.",
      "votes": null
    },
    {
      "id": "1905299",
      "postDate": "08/18/2022 22:53:23",
      "content": "<p>With this versions of tensorflow and keras I have an error:<br>\n<code>ModuleNotFoundError: No module named 'keras.engine.base_layer_v1'</code></p>",
      "rawMarkdown": "With this versions of tensorflow and keras I have an error:\n`ModuleNotFoundError: No module named 'keras.engine.base_layer_v1'`",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1904780,
      "author_name": "lucasjt",
      "author_url": "",
      "post_date": "08/18/2022 13:27:03",
      "content": "<p>It’s just an ancient artifact. Maybe from the aliens who built the pyramids. </p>\n<p>tensorflow==1.13.1<br>\nKeras==2.2.4</p>",
      "votes": null,
      "replies": [
        {
          "id": 1905202,
          "author_name": "jakewwill",
          "author_url": "",
          "post_date": "08/18/2022 20:02:39",
          "content": "<p>Thanks! Using those versions fixed the issue for me.</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 1905299,
          "author_name": "zlobriy",
          "author_url": "",
          "post_date": "08/18/2022 22:53:23",
          "content": "<p>With this versions of tensorflow and keras I have an error:<br>\n<code>ModuleNotFoundError: No module named 'keras.engine.base_layer_v1'</code></p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "1904478": "Hi, I don't know if this is part of the puzzle, but I'm having trouble loading the model for the SALT challenge. I can read the picklemodel file using joblib to get a keras model object, but the resulting model doesn't seem to be a full model object. Specifically, I get a\n\n`'Model' object has no attribute '_distribution_strategy'`\n\nerror when trying to make predictions. I'm thinking this might have something to do with different versions of tensorflow/keras being used, but I'm not sure. I'm using tensorflow 2.9.1 and python 3.8.3 if that's any help.",
    "1904780": "It’s just an ancient artifact. Maybe from the aliens who built the pyramids. \n\ntensorflow==1.13.1\nKeras==2.2.4",
    "1905202": "Thanks! Using those versions fixed the issue for me.",
    "1905299": "With this versions of tensorflow and keras I have an error:\n`ModuleNotFoundError: No module named 'keras.engine.base_layer_v1'`"
  },
  "source": "meta"
}