Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/jindongwang/transferlearning
/ convert_models_to_fp32
Function
convert_models_to_fp32
code/clip/utils.py:73–76 ·
view source on GitHub ↗
(model)
Source
from the content-addressed store, hash-verified
71
72
73
def
convert_models_to_fp32(model):
74
for
p in model.parameters():
75
p.data = p.data.float()
76
p.grad.data = p.grad.data.float()
Callers
1
finetune
Method · 0.90
Calls
1
parameters
Method · 0.45
Tested by
no test coverage detected