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

Method __init__

tensorpack/dataflow/common.py:304–312  ·  view source on GitHub ↗

Args: ds (DataFlow): input DataFlow func (datapoint -> datapoint | None): takes a datapoint and returns a new datapoint. Return None to discard/skip this datapoint.

(self, ds, func)

Source from the content-addressed store, hash-verified

302 """
303
304 def __init__(self, ds, func):
305 """
306 Args:
307 ds (DataFlow): input DataFlow
308 func (datapoint -> datapoint | None): takes a datapoint and returns a new
309 datapoint. Return None to discard/skip this datapoint.
310 """
311 super(MapData, self).__init__(ds)
312 self.func = func
313
314 def __iter__(self):
315 for dp in self.ds:

Callers 12

__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45
__init__Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected