Skip to content

Commit

Permalink
Another typo
Browse files Browse the repository at this point in the history
  • Loading branch information
corystephenson-db committed Jul 24, 2024
1 parent 051a01d commit 7c7a11d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions diffusion/datasets/image_caption.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
from torch.utils.data import DataLoader
from torchvision import transforms

from diffusion.datasets.laion.transforms import (LargestCenterSquare, RandomCropAspectRatioTransorm,
from diffusion.datasets.laion.transforms import (LargestCenterSquare, RandomCropAspectRatioTransform,
RandomCropBucketedAspectRatioTransform, RandomCropSquare)
from diffusion.datasets.utils import make_streams
from diffusion.models.text_encoder import MultiTokenizer
Expand Down Expand Up @@ -258,7 +258,7 @@ def build_streaming_image_caption_dataloader(
elif crop_type == 'random':
crop = RandomCropSquare(resize_size)
elif crop_type == 'aspect_ratio':
crop = RandomCropAspectRatioTransorm(resize_size, ar_bucket_boundaries) # type: ignore
crop = RandomCropAspectRatioTransform(resize_size, ar_bucket_boundaries) # type: ignore
elif crop_type == 'bucketed_aspect_ratio':
assert aspect_ratio_bucket_key is not None, 'aspect_ratio_bucket_key must be provided when using bucketed_aspect_ratio crop type'
crop = RandomCropBucketedAspectRatioTransform(resize_size) # type: ignore
Expand Down
2 changes: 1 addition & 1 deletion diffusion/datasets/laion/transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def __call__(self, img):
return img, c_top, c_left


class RandomCropAspectRatioTransorm:
class RandomCropAspectRatioTransform:
"""Assigns an image to a arbitrary set of aspect ratio buckets, then resizes and crops to fit into the bucket.
Args:
Expand Down

0 comments on commit 7c7a11d

Please sign in to comment.