szha commented on a change in pull request #12064: Allow stop of arange to be
inferred from dims.
URL: https://github.com/apache/incubator-mxnet/pull/12064#discussion_r210963879
##########
File path: scala-package/core/src/main/scala/org/apache/mxnet/NDArray.scala
##########
@@ -408,10 +408,10 @@ object NDArray extends NDArrayBase {
* @return NDArray of evenly spaced values in the specified range.
*/
def arange(start: Float, stop: Option[Float] = None, step: Float = 1.0f,
- repeat: Int = 1, ctx: Context = Context.defaultCtx,
+ repeat: Int = 1, inferRange: Boolean = false, ctx: Context =
Context.defaultCtx,
dType: DType = Base.MX_REAL_TYPE): NDArray = {
- val params = Map("start" -> start, "step" -> step,
- "repeat" -> repeat, "ctx" -> ctx.toString, "dtype" -> dType.toString())
+ val params = Map("start" -> start, "step" -> step, "repeat" -> repeat,
+ "infer_range" -> inferRange, "ctx" -> ctx.toString, "dtype" ->
dType.toString())
Review comment:
@lanking520 could you help review this part?
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services