Commit 0358aa86 authored by Davis King's avatar Davis King

merged

parents ffb44f83 985b9609
...@@ -145,7 +145,10 @@ namespace dlib ...@@ -145,7 +145,10 @@ namespace dlib
) )
{ {
typedef op_heatmap<image_type> op; typedef op_heatmap<image_type> op;
return matrix_op<op>(op(img,max(mat(img)),min(mat(img)))); if (img.size() != 0)
return matrix_op<op>(op(img,max(mat(img)),min(mat(img))));
else
return matrix_op<op>(op(img,0,0));
} }
// ---------------------------------------------------------------------------------------- // ----------------------------------------------------------------------------------------
...@@ -252,7 +255,10 @@ namespace dlib ...@@ -252,7 +255,10 @@ namespace dlib
) )
{ {
typedef op_jet<image_type> op; typedef op_jet<image_type> op;
return matrix_op<op>(op(img,max(mat(img)),min(mat(img)))); if (img.size() != 0)
return matrix_op<op>(op(img,max(mat(img)),min(mat(img))));
else
return matrix_op<op>(op(img,0,0));
} }
// ---------------------------------------------------------------------------------------- // ----------------------------------------------------------------------------------------
......
...@@ -33,7 +33,7 @@ namespace dlib ...@@ -33,7 +33,7 @@ namespace dlib
} }
} }
~transaction() ~transaction() throw (std::exception)
{ {
if (!committed) if (!committed)
db.exec("rollback"); db.exec("rollback");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment