Skip to content

Commit

Permalink
Fix possible error on maxpooling reachability
Browse files Browse the repository at this point in the history
  • Loading branch information
mldiego committed Aug 20, 2024
1 parent b827b36 commit 6e0ff35
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion code/nnv/engine/nn/layers/MaxPooling2DLayer.m
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@ function set_padding(obj, padding)
if n > 0
for i=1:n
m1 = length(images);
images = obj.stepSplitMultipleInputs(images, pad_image, split_pos(i, :, :), max_index{split_pos(i, 1), split_pos(i, 2), split_pos(i, 3)}, []);
images = obj.stepSplitMultipleInputs(images, pad_image, split_pos(i, :, :), max_index{split_pos(i, 1), split_pos(i, 2), split_pos(i, 3)}, [], lp_solver);
m2 = length(images);
if strcmp(dis_opt, 'display')
fprintf('\nSplit %d images into %d images', m1, m2);
Expand Down
2 changes: 2 additions & 0 deletions code/nnv/engine/utils/lpsolver.m
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@
% Define solver parameters
params = struct; % for now, leave default options/params
params.OutputFlag = 0; % no display
params.OptimalityTol = 1e-09;
params.FeasibilityTol = 1e-09;
result = gurobi(model, params);
fval = result.objval; % get fval value from results
% get exitflag and match those of linprog for easier parsing
Expand Down

0 comments on commit 6e0ff35

Please sign in to comment.