Skip to content

Commit

Permalink
Minor change to allow especial cases of affineMap
Browse files Browse the repository at this point in the history
  • Loading branch information
mldiego committed Jan 12, 2024
1 parent d75dfde commit 9ce26a8
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions code/nnv/engine/set/ImageStar.m
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,11 @@
end

if ~isempty(scale) && (isvector(scale) || isscalar(scale))
new_V = scale.*obj.V;
try
new_V = scale.*obj.V;
catch
new_V = pagemtimes(scale,obj.V);
end
elseif ~isempty(scale) && ismatrix(scale)
new_V = pagemtimes(scale,obj.V);
else
Expand Down Expand Up @@ -490,8 +494,8 @@
reshapedImage = ImageStar(V1,in_star.C, in_star.d, in_star.predicate_lb, in_star.predicate_ub);
end

% reshape an Imagestar with the target dimesion
function upsamplededImage = upsample(obj, scaleDim)
% upsample imagestar for specific dimension
function reshapedImage = upsample(obj, scaleDim)
if length(scaleDim) == 4
scaleDim = [scaleDim(4), scaleDim(3), 1];
elseif length(scaleDim) == 3
Expand Down

0 comments on commit 9ce26a8

Please sign in to comment.