Skip to content
This repository was archived by the owner on Nov 11, 2023. It is now read-only.

Update models.py#257

Open
karimkalimu wants to merge 1 commit intosvc-develop-team:4.1-Stablefrom
karimkalimu:patch-1
Open

Update models.py#257
karimkalimu wants to merge 1 commit intosvc-develop-team:4.1-Stablefrom
karimkalimu:patch-1

Conversation

@karimkalimu
Copy link
Copy Markdown

I added an if statement for MPS device because double is not supported for MPS device
if mps:
.float()
else:
.double()
https://discuss.pytorch.org/t/typeerror-cannot-convert-a-mps-tensor-to-float64-dtype-as-the-mps-framework-doesnt-support-float64-please-use-float32-instead/180852

I added an if statement for MPS device because double is not supported for MPS device
if mps: 
     .float()
else:
     .double() 
https://discuss.pytorch.org/t/typeerror-cannot-convert-a-mps-tensor-to-float64-dtype-as-the-mps-framework-doesnt-support-float64-please-use-float32-instead/180852
@ylzz1997 ylzz1997 requested a review from magic-akari June 25, 2023 14:56
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant