Skip to content

Commit

Permalink
Update common_deploy and the main README.md file, and rename Colab no…
Browse files Browse the repository at this point in the history
…tebook.

Signed-off-by: khaoula boutiche <[email protected]>
  • Loading branch information
KBOUSTM committed Feb 22, 2024
1 parent 0e7bdb2 commit 935b881
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 21 deletions.
28 changes: 9 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,22 +155,12 @@ on [How to install STM32 model zoo](https://wiki.st.com/stm32mcu/index.php?title
In [tutorials/notebooks](tutorials/notebooks/README.md) you will find a jupyter notebook that can be easily deployed on
Colab to exercise STM32 model zoo training scripts.
## Notes
In this project, we are using **TensorFLow version 2.8.3** following unresolved issues with newest versions of
TensorFlow, see [more](https://github.com/tensorflow/tensorflow/issues/56242).
**Warnings** :
* In this project we are using the `mlflow` library to log the results of different runs. Depending on which version of
Windows OS are you using or where you place the project the output log files might have a very long path which might
result in an error at the time of logging the results. As by default, Windows uses a path length limitation (MAX_PATH)
of 256 characters: Naming Files, Paths, and Namespaces. To avoid this potential error, create (or edit) a variable
named `LongPathsEnabled` in **Registry Editor**
under `Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem\` and assign it a value of `1`. This
will change the maximum length allowed for the file length on Windows machines and will avoid any errors resulting due
to this. For more details have a look at
this [link](https://knowledge.autodesk.com/support/autocad/learn-explore/caas/sfdcarticles/sfdcarticles/The-Windows-10-default-path-length-limitation-MAX-PATH-is-256-characters.html)
.
* If there are some white spaces in the paths (for Python, STM32CubeIDE, or, STM32Cube.AI local installation) this can
result in errors. So avoid having paths with white spaces in them.
> [!IMPORTANT]
> In this project, we are using **TensorFLow version 2.8.3** following unresolved issues with newest versions of TensorFlow, see [more](https://github.com/tensorflow/tensorflow/issues/56242).
>[!CAUTION]
> If there are some white spaces in the paths (for Python, STM32CubeIDE, or, STM32Cube.AI local installation) this can result in errors. So avoid having paths with white spaces in them.
>[!TIP]
> In this project we are using the `mlflow` library to log the results of different runs. Depending on which version of Windows OS are you using or where you place the project the output log files might have a very long path which might result in an error at the time of logging the results. As by default, Windows uses a path length limitation (MAX_PATH) of 256 characters: Naming Files, Paths, and Namespaces. To avoid this potential error, create (or edit) a variable named `LongPathsEnabled` in **Registry Editor** under **Computer/HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/FileSystem/** and assign it a value of `1`. This will change the maximum length allowed for the file length on Windows machines and will avoid any errors resulting due to this. For more details have a look at this [link](https://knowledge.autodesk.com/support/autocad/learn-explore/caas/sfdcarticles/sfdcarticles/The-Windows-10-default-path-length-limitation-MAX-PATH-is-256-characters.html).
4 changes: 2 additions & 2 deletions common/common_deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -279,8 +279,8 @@ def stmaic_local_call(session):
# Get footprints of the given model
results = cloud_analyze(ai=ai, model_path=model_path, optimization=optimization,
get_model_name_output=get_model_name_output)
needed_ram = round(int(results["ram_size"]) / 1024, 2)
needed_rom = round(int(results["rom_size"]) / 1024, 2)
needed_ram = int(results["ram_size"])
needed_rom = int(results["rom_size"])

with open(os.path.join(board.config.memory_pool_path), 'r') as f:
memory_pool = json.load(f)
Expand Down

0 comments on commit 935b881

Please sign in to comment.