예제 #1
0
def create_shapenet_voxel_dataloader(dset_type_, data_base_dir_, batch_size_):
    dataset = VoxelDataset(
        dset_type=dset_type_,
        data_base_dir=data_base_dir_,
        transform=transforms.Compose([transforms.ToTensor()]))
    dataloader = DataLoader(
        dataset,
        batch_size=batch_size_,
        shuffle=True,
        num_workers=4)
    return dataloader
예제 #2
0
def create_shapenet_voxel_dataloader(dset_type_,
                                     data_base_dir_,
                                     batch_size_,
                                     subset_size_=None):
    dataset_ = VoxelDataset(dset_type=dset_type_, data_base_dir=data_base_dir_)
    return create_dataloader_from_dataset(dataset_, batch_size_, subset_size_)