-
Notifications
You must be signed in to change notification settings - Fork 248
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add implementation for the algorithm described by the paper "Run Away From your Teacher: Understanding BYOL by a Novel Self-Supervised Approach" ( https://arxiv.org/abs/2011.10944 ) The RAFT class is essentially a copy-paste of the BYOL class, with slight changes to the `forward` method, which computes a different loss functionm making use of the new `raft_loss` function. RAFT's loss is the difference of two losses: an "alignment loss" between the projection of two different augmented views of the same image, to be minimized, and the "cross-model loss", to be maximized, which is the distance between the online and target representation of the same input, averaged over the two different views.
- Loading branch information
Showing
2 changed files
with
157 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
from byol_pytorch.byol_pytorch import BYOL | ||
from byol_pytorch.byol_pytorch import BYOL, RAFT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters