Skip to content

[Backfill corrections] Allocate enough shared memory for parallel prediction generation #1827

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 12, 2023

Conversation

nmdefries
Copy link
Contributor

@nmdefries nmdefries commented Apr 11, 2023

Description

Main change here is to make sure the docker container has enough shared memory to generate predictions.

Smaller changes:

  • Logging
  • Make sure receiving directory is cleared after a run
  • Check for "SIGBUS" message in log file

Changelog

  • Makefile
  • main.R

Fixes

Generating predictions in parallel (even with 2 cores) resulted in the error 'memcpy' resulted in a SIGBUS (no shared memory left). Docker containers have 64 MB shared memory by default, which is apparently sufficient for modeling training in parallel but not generating predictions. This change assigns 2 GB of shared memory, which is enough for generating predictions in parallel with up to 3 cores (and maybe more -- didn't test).

@nmdefries nmdefries marked this pull request as ready for review April 11, 2023 21:37
@nmdefries nmdefries requested a review from krivard April 11, 2023 21:37
Copy link
Contributor

@krivard krivard left a comment

Choose a reason for hiding this comment

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

👍

nice extension of the log checks; it's always easier on monitoring if the make fails when something has gone wrong

@nmdefries nmdefries merged commit 7ef2f5b into main Apr 12, 2023
@nmdefries nmdefries deleted the ndefries/backfill/mem-log-make-cleanup branch April 12, 2023 14:05
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