You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2019/10/31 05:09:20 UTC
[GitHub] [incubator-mxnet] reminisce commented on a change in pull request
#16667: [NumPy] Add NumPy support for Cholesky decomposition
reminisce commented on a change in pull request #16667: [NumPy] Add NumPy support for Cholesky decomposition
URL: https://github.com/apache/incubator-mxnet/pull/16667#discussion_r340962172
##########
File path: src/operator/tensor/la_op-inl.h
##########
@@ -125,6 +125,11 @@ struct potrf {
Stream<xpu> *s, const nnvm::NodeAttrs& attrs) {
const LaCholeskyParam& param = nnvm::get<LaCholeskyParam>(attrs.parsed);
if ( A.dptr_ != B.dptr_ ) Copy(B, A, s);
+ for (int i = 0; i < A.shape_.kDimension; ++i) {
Review comment:
For zero-size check, you can simply do
```cpp
if (A.Size() == 0U) {
return;
}
```
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services