Skip to content

aggressive fix#238

Closed
lgarithm wants to merge 3 commits intomasterfrom
lg-debug
Closed

aggressive fix#238
lgarithm wants to merge 3 commits intomasterfrom
lg-debug

Conversation

@lgarithm
Copy link
Copy Markdown
Member

@lgarithm lgarithm commented Mar 8, 2020

  • make life scope of thread_pool shorter
  • disabled thread_local

@lgarithm lgarithm requested a review from ganler March 8, 2020 17:17
Comment thread src/paf.cpp
Comment on lines +41 to +43
ttl::tensor<float, 3> upsample_conf_(upsample_conf_dim); // 5FPS
ttl::tensor<float, 3> upsample_paf_(upsample_paf_dim); // 5FPS
peak_finder_t<float> peak_finder_(
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After removing thread_local, it did work. But this will hurt performance. Especially there's much device/host allocation stuff in peak_finder_t. I'd like to figure out the reason why this thread_local variable failed to deconstruct. BTW, I think we'd better make a "lazy allocation" in peak_finder_t. (it hurts performance when we don't use the gpu version of maxpooling).

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this fix is too aggressive.
I only merged the first commit.

Comment on lines +25 to +42
DEFINE_string(data_dir, "../../data/media", "path to data folder");
DEFINE_string(image_files,
"../../data/media/COCO_val2014_000000000192.jpg,"
"../../data/media/COCO_val2014_000000000459.jpg,"
"../../data/media/COCO_val2014_000000000415.jpg,"
"../../data/media/COCO_val2014_000000000564.jpg,"
"../../data/media/COCO_val2014_000000000294.jpg,"
"../../data/media/COCO_val2014_000000000623.jpg,"
"../../data/media/COCO_val2014_000000000357.jpg,"
"../../data/media/COCO_val2014_000000000488.jpg,"
"../../data/media/COCO_val2014_000000000589.jpg,"
"../../data/media/COCO_val2014_000000000474.jpg,"
"../../data/media/COCO_val2014_000000000338.jpg,"
"../../data/media/COCO_val2014_000000000569.jpg,"
"../../data/media/COCO_val2014_000000000544.jpg,"
"../../data/media/COCO_val2014_000000000428.jpg,"
"../../data/media/COCO_val2014_000000000536.jpg,"
"../../data/media/COCO_val2014_000000000395.jpg",
"COCO_val2014_000000000192.jpg,"
"COCO_val2014_000000000459.jpg,"
"COCO_val2014_000000000415.jpg,"
"COCO_val2014_000000000564.jpg,"
"COCO_val2014_000000000294.jpg,"
"COCO_val2014_000000000623.jpg,"
"COCO_val2014_000000000357.jpg,"
"COCO_val2014_000000000488.jpg,"
"COCO_val2014_000000000589.jpg,"
"COCO_val2014_000000000474.jpg,"
"COCO_val2014_000000000338.jpg,"
"COCO_val2014_000000000569.jpg,"
"COCO_val2014_000000000544.jpg,"
"COCO_val2014_000000000428.jpg,"
"COCO_val2014_000000000536.jpg,"
"COCO_val2014_000000000395.jpg",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we just specify the folder and glob the image files using filesystem.

@lgarithm lgarithm changed the title conservative fix aggressive fix Mar 8, 2020
luomai added a commit that referenced this pull request Mar 8, 2020
debug and cleanup (cherrypicked from #238)
@lgarithm lgarithm closed this Mar 8, 2020
@lgarithm lgarithm deleted the lg-debug branch April 9, 2020 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants