Open jatkinson1000 opened 2 months ago
Copying @ElliottKasoar's comment from #81
FTorch with InferenceMode and NoGradMode
sections), benefits were less clear, but in general it is expected to be at least as fasttorch::AutoGradMode enable_grad(requires_grad);
with c10::InferenceMode guard(requires_grad);
in all ctorch.cpp functions, but ideally both options would be presented to usersNoGradMode
, so cannot be used in all cases
Originally commented by @ElliottKasoar as part of #103
"Looking at the docs we'd maybe want to create an optional argument
bool :: inference mode
and if set to true enablec10::InferenceMode
for the function as a block.