Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/janfreyberg/pytorch-revgrad
A minimal pytorch package implementing a gradient reversal layer.
https://github.com/janfreyberg/pytorch-revgrad
domain-adaptation gradient-reversal pytorch
Last synced: 3 days ago
JSON representation
A minimal pytorch package implementing a gradient reversal layer.
- Host: GitHub
- URL: https://github.com/janfreyberg/pytorch-revgrad
- Owner: janfreyberg
- License: mit
- Created: 2019-03-30T12:10:45.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2024-11-04T15:03:33.000Z (2 months ago)
- Last Synced: 2024-12-29T01:07:10.796Z (10 days ago)
- Topics: domain-adaptation, gradient-reversal, pytorch
- Language: Python
- Homepage:
- Size: 42 KB
- Stars: 157
- Watchers: 3
- Forks: 14
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# `pytorch-revgrad`
[![PyPI version](https://badge.fury.io/py/pytorch-revgrad.svg)](https://badge.fury.io/py/pytorch-revgrad)
[![Coverage Status](https://coveralls.io/repos/github/janfreyberg/pytorch-revgrad/badge.svg?branch=master)](https://coveralls.io/github/janfreyberg/pytorch-revgrad?branch=master)
[![ci status](https://travis-ci.org/janfreyberg/pytorch-revgrad.svg?branch=master)](https://travis-ci.com/janfreyberg/pytorch-revgrad)
![python version](https://camo.githubusercontent.com/0a3ef56c3f80aca9bc6bafeab605803d81fe2284/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f707974686f6e2d332e352532422d626c75652e737667)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)This package implements a gradient reversal layer for pytorch modules.
## Example usage
```python
import torchfrom pytorch_revgrad import RevGrad
model = torch.nn.Sequential(
torch.nn.Linear(10, 5),
torch.nn.Linear(5, 2),
RevGrad()
)
```