MCPcopy Create free account
hub / github.com/CompVis/flow-poke-transformer / __init__

Method __init__

myriad/data_billiards.py:346–365  ·  view source on GitHub ↗
(
        self,
        batch_size: int,
        train=None,
        validation=None,
        num_workers=4,
        val_batch_size: int | None = None,
        val_num_workers: int | None = None,
        pre_collation_factor: int = 1,
    )

Source from the content-addressed store, hash-verified

344class BilliardSimDataModule:
345
346 def __init__(
347 self,
348 batch_size: int,
349 train=None,
350 validation=None,
351 num_workers=4,
352 val_batch_size: int | None = None,
353 val_num_workers: int | None = None,
354 pre_collation_factor: int = 1,
355 ):
356 super().__init__()
357 self.batch_size = batch_size
358 self.num_workers = num_workers
359 self.train = train
360 self.validation = validation
361 self.val_batch_size = val_batch_size if val_batch_size is not None else batch_size
362 self.val_num_workers = val_num_workers if val_num_workers is not None else num_workers
363 self.pre_collation_factor = pre_collation_factor
364 if self.pre_collation_factor > 1:
365 assert self.batch_size % self.pre_collation_factor == 0
366
367 def make_loader(
368 self,

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected