[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #43780] Single-precision diagonal matrix expan
From: |
Rik |
Subject: |
[Octave-bug-tracker] [bug #43780] Single-precision diagonal matrix expanded when multiplying logical vector |
Date: |
Mon, 12 Oct 2015 22:35:44 +0000 |
User-agent: |
Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1) |
Follow-up Comment #2, bug #43780 (project octave):
Just had time to test this. Unfortunately it fails to compile
libinterp/operators/op-bm-bm.cc: In function 'void install_bm_bm_ops()':
libinterp/operators/op-bm-bm.cc:168:2: error:
'oct_conv_float_matrix_to_bool_matrix' was not declared in this scope
libinterp/operators/op-bm-bm.cc:169:49: error: 'octave_float_scalar' has not
been declared
libinterp/operators/op-bm-bm.cc:170:2: error:
'oct_conv_float_scalar_to_bool_matrix' was not declared in this scope
Looking to code by example, I used the DEFCONVFN macro as was done earlier in
op-bm-bm.cc.
DEFCONVFN (matrix_to_bool_matrix, matrix, bool)
DEFCONVFN (scalar_to_bool_matrix, scalar, bool)
// Added to match declaration for doubles
DEFCONVFN (float_matrix_to_bool_matrix, float_matrix, bool)
DEFCONVFN (float_scalar_to_bool_matrix, float_scalar, bool)
This leads to
libinterp/operators/op-bm-bm.cc: In function 'octave_base_value*
oct_conv_float_scalar_to_bool_matrix(const octave_base_value&)':
libinterp/operators/op-bm-bm.cc:131:102: error: 'octave_float_scalar' does not
name a type
libinterp/operators/op-bm-bm.cc:131:204: error: 'v' was not declared in this
scope
libinterp/operators/op-bm-bm.cc: At global scope:
libinterp/operators/op-bm-bm.cc:131:28: warning: unused parameter 'a'
[-Wunused-parameter]
libinterp/operators/op-bm-bm.cc: In function 'void install_bm_bm_ops()':
libinterp/operators/op-bm-bm.cc:169:49: error: 'octave_float_scalar' has not
been declared
so I commented out the scalar instance of DEFCONVFN and INSTALL_CONVOP. Now
it compiles. But I get the same error as before
x0 = diag(ones(1E6, 1, "single")) * ones(1E6, 1, "logical");
error: out of memory or dimension too large for Octave's index type
Just guessing, but maybe the conversions need to be somewhere in the *fdm*
files for float_diagonal_matrix in the operator directory.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?43780>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/