piiswrong commented on a change in pull request #10451: [MXNET-432] Add Foreach
URL: https://github.com/apache/incubator-mxnet/pull/10451#discussion_r182570388
 
 

 ##########
 File path: python/mxnet/ndarray/contrib.py
 ##########
 @@ -96,3 +96,18 @@ def rand_zipfian(true_classes, num_sampled, range_max, 
ctx=None):
     expected_count_sampled = expected_prob_sampled * num_sampled
     return sampled_classes, expected_count_true, expected_count_sampled
 # pylint: enable=line-too-long
+
+def foreach(func, input, init_states, back_prop=False, name="foreach"):
 
 Review comment:
   back_prop -> Imperative::Get()->is_recording()
   add OpContext::is_record at backend

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to