3 À<×ek ã @ sN d dl Z d dlZd dlZddlmZ d dljZejj ƒ Z G dd„ dejƒZdS )é Né )Úbasec s, e Zd ZdZ‡ fdd„Z‡ fdd„Z‡ ZS )Úcalc_isolated_coreszÒ Calculates and returns isolated cores. The argument specifies how many cores per socket reserve for housekeeping. If not specified, 1 core per socket is reserved for housekeeping and the rest is isolated. c s t t| ƒjddƒ d S )Nr r )Úsuperr Ú__init__)Úself)Ú __class__© ú2/usr/lib/python3.6/function_calc_isolated_cores.pyr s zcalc_isolated_cores.__init__c sP t t| ƒj|ƒsd S d}t|ƒdkrj|d jƒ sBt|d ƒdk r^tjd|d | jf ƒ d S t|d ƒ}i }x–t j tjj tjdƒƒD ]|}tjj|ƒdd … }|jƒ r†tjj |dƒ}tjj|ƒsÔtjd||f ƒ q†| jj|ƒjƒ }|jƒ r†|j|g ƒ|g ||<