Caffe2 - Python API
A deep learning, cross platform ML framework
Public Member Functions | Public Attributes | List of all members
caffe2.python.dataio.ReaderWithLimit Class Reference
Inheritance diagram for caffe2.python.dataio.ReaderWithLimit:
caffe2.python.dataio.ReaderWithLimitBase caffe2.python.dataio.Reader

Public Member Functions

def __init__ (self, reader, num_iter=1)
 
def setup_limiter (self, global_init_net, global_finish_net)
 
def check_limiter_condition (self, stop_condition_net)
 
- Public Member Functions inherited from caffe2.python.dataio.ReaderWithLimitBase
def __init__ (self, reader)
 
def setup_ex (self, global_init_net, global_finish_net)
 
def read_ex (self, local_init_net, local_finish_net)
 
def setup_limiter (self, global_init_net, global_finish_net)
 
def check_limiter_condition (self, stop_condition_net)
 
def data_finished (self)
 
- Public Member Functions inherited from caffe2.python.dataio.Reader
def __init__ (self, schema=None)
 
def schema (self)
 
def setup_ex (self, init_net, finish_net)
 
def read_ex (self, local_init_net, local_finish_net)
 
def read_record_ex (self, local_init_net, local_finish_net)
 
def read (self, read_net)
 
def reset (self, net)
 
def read_record (self, read_net)
 
def execution_step (self, reader_net_name=None, external_should_stop=None)
 

Public Attributes

 counter
 
 num_iter
 
- Public Attributes inherited from caffe2.python.dataio.ReaderWithLimitBase
 reader
 
 net
 
 should_stop
 

Detailed Description

Reader that stops after `num_iter` batches.

If `num_iter` <= 0 or is None, reverts to an unconstrained reader that
exports a boolean blob indicating that the reader has exhausted
the data steam.

Definition at line 410 of file dataio.py.

Constructor & Destructor Documentation

def caffe2.python.dataio.ReaderWithLimit.__init__ (   self,
  reader,
  num_iter = 1 
)
Class initializer.

Args:
    reader: The underlying reader object doing the actual read.
    num_iter: Number of batches to read. If `None`,
the class reverts to a normal reader except that it also
produces a data_finished blob as a side effect to indicate
whether the input stream is exhausted.

Definition at line 417 of file dataio.py.


The documentation for this class was generated from the following file: