X Tutup
Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/api/c/binary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,13 @@ static af_err af_arith_sparse_dense(af_array *out, const af_array lhs,
const bool reverse = false) {
try {
const common::SparseArrayBase linfo = getSparseArrayBase(lhs);
const ArrayInfo &rinfo = getInfo(rhs);
if (linfo.ndims() > 2) {
AF_ERROR(
"Sparse-Dense arithmetic operations cannot be used in batch "
"mode",
AF_ERR_BATCH);
}
const ArrayInfo &rinfo = getInfo(rhs);

const af_dtype otype = implicit(linfo.getType(), rinfo.getType());
af_array res;
Expand Down
X Tutup