Skip to content

Commit

Permalink
feat(ml): activate cutout for object detector training with torch bac…
Browse files Browse the repository at this point in the history
…kend
  • Loading branch information
beniz authored and mergify[bot] committed Dec 6, 2021
1 parent 35a16df commit 8a34aa1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/backends/torch/torchdataaug.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ namespace dd
applyRotateBBox(bboxes, static_cast<float>(src.cols),
static_cast<float>(src.rows), rot);
}
// XXX: no cutout with bboxes (yet)
applyCutout(src, _cutout_params);
GeometryParams geoparams = _geometry_params;
cv::Mat src_c = src.clone();
applyGeometry(src_c, geoparams, true);
Expand Down
2 changes: 1 addition & 1 deletion tests/ut-torchapi.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1387,7 +1387,7 @@ TEST(torchapi, service_train_object_detection)
"type\":\"ADAM\",\"test_interval\":200},\"net\":{\"batch_size\":2,"
"\"test_batch_size\":2},\"resume\":false,\"mirror\":true,\"rotate\":"
"true,\"crop_size\":224,"
"\"cutout\":0.5,\"geometry\":{\"prob\":0.1,\"persp_horizontal\":"
"\"cutout\":0.1,\"geometry\":{\"prob\":0.1,\"persp_horizontal\":"
"true,\"persp_vertical\":true,\"zoom_in\":true,\"zoom_out\":true,"
"\"pad_mode\":1},\"noise\":{\"prob\":0.01},\"distort\":{\"prob\":0."
"01}},\"input\":{\"seed\":12347,"
Expand Down

0 comments on commit 8a34aa1

Please sign in to comment.