kadirnar / kadirnar/codeformer-pip
Input type (MPSFloatType) and weight type (torch.FloatTensor) should be the same
- Dominant language
- Python
- Stars
- 36
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
Hello, I am on M1 Mac, with MPS, and the solution is here in case somebody encounters the same issue (just a quick, dirty workaround) is go to site-packages/codeformer/app.py
replace line 71:
```
# REPLACE THIS LINE
# device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
device = torch.device('mps')
```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with site-packages/codeformer/app.py at line 71 and inspect how the device is selected. Reproduce the reported input/weight type mismatch on an M1 Mac with MPS, then verify that the device selection avoids the error. Done means the application runs without the reported type mismatch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100