hlibbabii / hlibbabii/log-recommender
Not load torch lib if not necessary
- Dominant language
- Python
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
When running some scripts or unit-tests torch lib is loaded. That makes the running slow.
Torch shouldn't get imported when it's not necessary
For example, there can be a case when module `lib` has functions `func1` and `func2`. However, only `func1` uses torch library. Thus, if some module needs to use `func2`, torch will still be loaded because, it's normally imported globally in a module.
Contributor guide
No contributing guide indexed for this repository
Research direction
The issue does not name a file or specific test. Start by tracing which module-level import loads torch when running the affected scripts or unit-tests, then compare paths that use only functions such as func2. Done means torch is not loaded for paths that do not need it, while the relevant unit-tests still pass.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning, performance
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100