th3-j0k3r commited on
Commit
26f5357
·
verified ·
1 Parent(s): 1af213c

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +5 -2
README.md CHANGED
@@ -16,12 +16,15 @@ nested Lambda — but Keras deserializes sub-models recursively and executes it
16
  ## Reproduce
17
  > Use **Python 3.10+** (verified on Python 3.12 / TensorFlow 2.21 / Keras 3.14 / modelscan 0.8.8).
18
  > TensorFlow on the EOL Python 3.9 can abort at import on macOS arm64 (`mutex lock failed`),
19
- > which is unrelated to this issue.
20
 
21
  ```bash
 
 
22
  pip install 'modelscan[tensorflow]' tensorflow keras
 
23
  # 1) scanner says it is safe:
24
- modelscan -p model.keras # -> No issues found! 🎉
25
  # 2) loading it executes code:
26
  python -c "import keras; keras.saving.load_model('model.keras', safe_mode=False, compile=False)"
27
  ls keras_poc_executed.txt # marker proves code ran on load
 
16
  ## Reproduce
17
  > Use **Python 3.10+** (verified on Python 3.12 / TensorFlow 2.21 / Keras 3.14 / modelscan 0.8.8).
18
  > TensorFlow on the EOL Python 3.9 can abort at import on macOS arm64 (`mutex lock failed`),
19
+ > which is unrelated to this issue. The clean venv below avoids it.
20
 
21
  ```bash
22
+ # Clean Python 3.10+ environment (so `python` is correct, not a system 3.9)
23
+ python3.12 -m venv venv && source venv/bin/activate
24
  pip install 'modelscan[tensorflow]' tensorflow keras
25
+
26
  # 1) scanner says it is safe:
27
+ modelscan -p model.keras # -> No issues found
28
  # 2) loading it executes code:
29
  python -c "import keras; keras.saving.load_model('model.keras', safe_mode=False, compile=False)"
30
  ls keras_poc_executed.txt # marker proves code ran on load