Skip to content

Commit 42342ea

Browse files
committed
Fixed a bug where scale factors would force an output to be cast to double
1 parent 01e5a22 commit 42342ea

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

MappedTensor.m

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -525,6 +525,12 @@ function delete(mtVar)
525525
tfData = mtVar.fRealFactor .* tfData;
526526
end
527527

528+
% - Recast data, if required, to take into account scaling in
529+
% other class
530+
if (mtVar.bMustCast)
531+
tfData = cast(tfData, mtVar.strClass);
532+
end
533+
528534
% - Permute dimensions
529535
tfData = permute(tfData, mtVar.vnDimensionOrder);
530536

0 commit comments

Comments
 (0)