ChaiBapchya commented on a change in pull request #15593: Large Index Support
for Slice
URL: https://github.com/apache/incubator-mxnet/pull/15593#discussion_r305589010
##########
File path: src/operator/tensor/matrix_op-inl.h
##########
@@ -1323,12 +1323,12 @@ inline bool SliceLikeShape(const nnvm::NodeAttrs&
attrs,
inline void SliceLikeInferRanges(const mxnet::TShape& dshape,
const mxnet::TShape& fshape,
const mxnet::Tuple<int>& axes,
- mxnet::Tuple<dmlc::optional<int>>*
param_begin,
- mxnet::Tuple<dmlc::optional<int>>* param_end,
- mxnet::Tuple<dmlc::optional<int>>*
param_step) {
- std::vector<dmlc::optional<int>> pb(dshape.ndim());
- std::vector<dmlc::optional<int>> pe(dshape.ndim());
- std::vector<dmlc::optional<int>> ps(dshape.ndim());
+ mxnet::Tuple<dmlc::optional<index_t>>*
param_begin,
+ mxnet::Tuple<dmlc::optional<index_t>>*
param_end,
+ mxnet::Tuple<dmlc::optional<index_t>>*
param_step) {
+ std::vector<dmlc::optional<index_t>> pb(dshape.ndim());
+ std::vector<dmlc::optional<index_t>> pe(dshape.ndim());
+ std::vector<dmlc::optional<index_t>> ps(dshape.ndim());
if (axes.ndim() == 0) {
for (int i = 0; i < dshape.ndim(); ++i) {
Review comment:
can we use `size_t` or `index_t` here?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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