Skip to content
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

Setting a nice parameter (the job priority). #264

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

joannaWojS
Copy link
Collaborator

No description provided.

@@ -4,7 +4,7 @@
__all__ = ["slurm_lines", "rc_lines"]


def slurm_lines(queue, job_name, array=None, mem=None, out_name=None):
def slurm_lines(queue, job_name, array=None, mem=None, out_name=None, nice_parameter=None):
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm not sure if None is a 'good' value for this parameter. Maybe the default should be 0 (i.e., no change in priorities). I have to check this but '#SBATCH --nice=None' seems quite anomalous

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

In the config file default value is equal 0.

@@ -20,6 +20,8 @@ def slurm_lines(queue, job_name, array=None, mem=None, out_name=None):
Requested memory. If None cluster default (5 GB) will be used
out_name : None or str
If the output should be written to a specific output file
nice_parameter : None or int
Copy link
Collaborator

Choose a reason for hiding this comment

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

Again, maybe there just int (or you should add a line of code later that do something like: 'ok if this is none put it to 0' (but easier to ask only for an int)

@@ -21,4 +29,6 @@ general:
nsb: [0.5, 1.0, 1.5, 2.0, 2.5, 3.0]
env_name: magic-lst # name of the conda environment to be used to process data.
cluster: "SLURM" # cluster management system on which data are processed. At the moment we have only SLURM available, in the future maybe also condor (PIC, CNAF).
nice: 0 # Set the job priority >0. A lower nice value increases the priority, while a higher value reduces it. Default value is equal 0.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe just add that it must be an int, in the range +/- 2147483645 (but only positive values, i.e., lower priority, can be used by standard users)

Copy link

codecov bot commented Sep 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 77.23%. Comparing base (d8a8ce6) to head (cab1067).
Report is 4 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #264   +/-   ##
=======================================
  Coverage   77.23%   77.23%           
=======================================
  Files          21       21           
  Lines        2614     2614           
=======================================
  Hits         2019     2019           
  Misses        595      595           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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