You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by gi...@git.apache.org on 2017/08/15 09:15:22 UTC

[GitHub] squidszyd commented on issue #7427: how to set dataiter with multi data?

squidszyd commented on issue #7427: how to set dataiter with multi data?
URL: https://github.com/apache/incubator-mxnet/issues/7427#issuecomment-322420119
 
 
   Use collections.namedtuple:
   Batch = namedtuple('Batch',['data', 'label'])
   def __iter__(self):
       ...
       yield Batch(data=[data1, data2, data3,...], label=[...])
   @property
   def provide_data(self):
        return [('data1', shape1), ('data2', shape2), ('data3', shape3), ...]
   
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services