JonathanMurray / JonathanMurray/dialog-tree-py
All images are loaded (including ones that aren't used in the current script)
Open
good first issue
- Dominant language
- Python
- Stars
- 24
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
When starting up, all image files in the image directory are loaded into memory.
```
image_paths = os.listdir(IMG_DIR)
images = {path.split(".")[0]: load_image(path) for path in image_paths}
```
This makes startup slower, produces irrelevant logs and will grow as a problem if more image files are added to the repo.
Solution:
When starting up a script, only image files referenced in that script should be loaded.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.