[2147a4]: / bme1312 / .ipynb_checkpoints / lab2-checkpoint.py

Download this file

13 lines (8 with data), 345 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
import itertools
from .utils import imgshow, imsshow, image_mask_overlay
from .utils import compute_num_params as compute_params
from .dataset import ImageFolder, Test_ImageFolder, get_loader
from .solver import Lab2Solver as Solver
def fetch_batch_sample(loader, idx):
batch = next(itertools.islice(loader, idx, None))
return batch