MCPcopy Index your code
hub / github.com/tensorpack/tensorpack / __init__

Method __init__

tensorpack/dataflow/common.py:401–409  ·  view source on GitHub ↗

Args: ds (DataFlow): input DataFlow num (int): number of times to repeat each datapoint.

(self, ds, num)

Source from the content-addressed store, hash-verified

399 """
400
401 def __init__(self, ds, num):
402 """
403 Args:
404 ds (DataFlow): input DataFlow
405 num (int): number of times to repeat each datapoint.
406 """
407 self.num = int(num)
408 assert self.num >= 1, self.num
409 super(RepeatedDataPoint, self).__init__(ds)
410
411 def __len__(self):
412 return len(self.ds) * self.num

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected