This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import tensorflow as tf | |
| from tensorflow.keras.preprocessing import image | |
| from tensorflow.keras.applications import densenet | |
| import numpy as np | |
| def decode_prediction(predicted, char_set, length=2): | |
| l = len(char_set) | |
| chars = [] | |
| for i in range(length): | |
| chars.append(char_set[np.argmax(predicted[i * l : (i + 1) * l])]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from pathlib import Path | |
| configured_path = Path(__file__).parent.parent / "cpython" / "installs" / "python-3.11.3" / "lib" / "python3.11" | |
| archive_path = Path(__file__).parent.parent / ".." / "temp" / "cpython-3.11.3" / "Lib" | |
| configured_lib = configured_path | |
| archive_lib = archive_path |
OlderNewer