mirror of
https://github.com/hpcaitech/ColossalAI.git
synced 2025-09-04 18:40:28 +00:00
[hotfix] set return_outputs=False in examples and polish code (#5404)
* fix: simplify merge_batch * fix: use return_outputs=False to eliminate extra memory consumption * feat: add return_outputs warning * style: remove `return_outputs=False` as it is the default value
This commit is contained in:
@@ -74,7 +74,7 @@ def run_fn(init_method, model_fn, data_gen_fn, output_transform_fn) -> Optional[
|
||||
loss = criterion(outputs[output_key])
|
||||
return loss
|
||||
|
||||
booster.execute_pipeline(data_iter, model, _criterion, optimizer, return_loss=True, return_outputs=False)
|
||||
booster.execute_pipeline(data_iter, model, _criterion, optimizer, return_loss=True)
|
||||
optimizer.step()
|
||||
|
||||
except Exception as e:
|
||||
|
Reference in New Issue
Block a user