Skip to content

Instantly share code, notes, and snippets.

"""
Affine transforms implemented on torch tensors, and
only requiring one interpolation
Included:
- Affine()
- AffineCompose()
- Rotation()
- Translation()
- Shear()
"""
Custom datasets from both in-memory and out-of-memory data
"""
import torch.utils.data as data
from PIL import Image
import os
import os.path