os.sched_setparam()

os.sched_setparam(pid, param) Set a scheduling parameters for the process with PID pid. A pid of 0 means the calling process. param is a sched_param instance.

os.sched_setaffinity()

os.sched_setaffinity(pid, mask) Restrict the process with PID pid (or the current process if zero) to a set of CPUs. mask is an iterable of integers representing the set of CPUs to which the process should be restricted.

os.sched_rr_get_interval()

os.sched_rr_get_interval(pid) Return the round-robin quantum in seconds for the process with PID pid. A pid of 0 means the calling process.

os.sched_param.sched_priority

sched_priority The scheduling priority for a scheduling policy.

os.sched_param

class os.sched_param(sched_priority) This class represents tunable scheduling parameters used in sched_setparam(), sched_setscheduler(), and sched_getparam(). It is immutable. At the moment, there is only one possible parameter: sched_priority The scheduling priority for a scheduling policy.

os.sched_get_priority_min()

os.sched_get_priority_min(policy) Get the minimum priority value for policy. policy is one of the scheduling policy constants above.

os.sched_get_priority_max()

os.sched_get_priority_max(policy) Get the maximum priority value for policy. policy is one of the scheduling policy constants above.

os.sched_getscheduler()

os.sched_getscheduler(pid) Return the scheduling policy for the process with PID pid. A pid of 0 means the calling process. The result is one of the scheduling policy constants above.

os.sched_getparam()

os.sched_getparam(pid) Return the scheduling parameters as a sched_param instance for the process with PID pid. A pid of 0 means the calling process.

os.sched_getaffinity()

os.sched_getaffinity(pid) Return the set of CPUs the process with PID pid (or the current process if zero) is restricted to.