Transform objective function in osr to full matrix

If the objective function only has one element, the scalar product of a sparse matrix and a full matrix is sparse (in contrast to two or more elements). This crashes the osr code subsequently.
time-shift
Johannes Pfeifer 2014-11-03 15:29:21 +01:00
parent 4aaebfbe46
commit 7b1663281b
1 changed files with 1 additions and 1 deletions

View File

@ -86,4 +86,4 @@ switch info(1)
end
vx = get_variance_of_endogenous_variables(dr,i_var);
loss = weights(:)'*vx(:);
loss = full(weights(:)'*vx(:));