facebookresearch / ClassyVision

An end-to-end PyTorch framework for image and video classification
https://classyvision.ai
MIT License
1.59k stars 278 forks source link

Add stateless output option for classy block (#101) #785

Closed kylelee82 closed 2 years ago

kylelee82 commented 2 years ago

Summary: X-link: https://github.com/fairinternal/ClassyVision/pull/101

This diff adds a stateless output option within ClassyBlock.py when if the environmental variable STATELESS_CLASSY_OUTPUT is enabled, self.output within ClassyBlock never hold the value of the last output (and thus is stateless). This is useful to prevent certain race conditions, while the default condition will still be maintained if the flag is not enabled to maintain original behavior.

Differential Revision: D35662345

facebook-github-bot commented 2 years ago

This pull request was exported from Phabricator. Differential Revision: D35662345