зеркало из https://github.com/microsoft/torchgeo.git
renamed default_loader to pil_loader
This commit is contained in:
Родитель
b4f8a25514
Коммит
6b4bf67ed6
|
@ -25,7 +25,8 @@ from rasterio.vrt import WarpedVRT
|
|||
from rtree.index import Index, Property
|
||||
from torch import Tensor
|
||||
from torch.utils.data import Dataset
|
||||
from torchvision.datasets.folder import ImageFolder, default_loader
|
||||
from torchvision.datasets.folder import ImageFolder
|
||||
from torchvision.datasets.folder import default_loader as pil_loader
|
||||
|
||||
from .utils import BoundingBox, disambiguate_timestamp
|
||||
|
||||
|
@ -590,7 +591,7 @@ class VisionClassificationDataset(VisionDataset, ImageFolder): # type: ignore[m
|
|||
self,
|
||||
root: str,
|
||||
transforms: Optional[Callable[[Dict[str, Tensor]], Dict[str, Tensor]]] = None,
|
||||
loader: Optional[Callable[[str], Any]] = default_loader,
|
||||
loader: Optional[Callable[[str], Any]] = pil_loader,
|
||||
) -> None:
|
||||
"""Initialize a new VisionClassificationDataset instance.
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче