Client classes

_Client Class

class rrClient._Client_ALL

Overal information about rrClients. Please see _ClientStatusThread and _ClientHardware for examples.

class _Client_ALL properties:

Type

Name

Description

_ClientHardware

hw

Hardware/OS information of the client

int

listIdx

Index ID of the client

class rrC::_ClientStatus_template

status

Status of client. Class is _ClientStatus_ALL

class _Client_ALL functions:

Return Type

Name

Description

bool

isJobSelected()

Is a job that the client is rendering currently selected?

Note

Only available when the script runs in rrControl or rrSubmitter

bool

isSelected()

Is the client selected?

Note

Only available when the script runs in rrControl or rrSubmitter

_ClientStatusThread

jobThread(int threadID)

Returns the render thread by ID. The maximum threadID is _ClientStatus_ALL.maxJobThreads.

str

name()

_ClientStatus Class

class rrClient._ClientStatus_ALL

Information about rrClients current status.

Example, list clients and if they are enabled:

from rr_python_utils.load_rrlib import rrLib
import rr_python_utils.connection as rr_connect

tcp = rr_connect.server_connect()
tcp.clientGetList()

for i in range(tcp.clients.count()):
    status = tcp.clients.at(i)
    print(f"{status.name}" is {status.enabled})

class _ClientStatus_ALL properties:

Type

Name

Description

float

CPU_Usage

0-100% all CPUs

float

GPU_Usage

0-100% all GPUs

int

StructureID

int

VariablesID

bool

enabled

Client is Enabled

bool

isRunningAsService

True if launched via clientService

str

loggedArtist

Users logged to the client

int

maxJobThreads

Number of Job Threads

str

name

Client Name

int

netTrafficSystem_IN

Traffic IN in MB/s. Note: Does not work for Cloud Clients! Use the traffic within the job thread instead.

int

netTrafficSystem_OUT

Traffic OUT in MB/s. Note: Does not work for Cloud Clients! Use the traffic within the job thread instead.

int

noUserInteraction

minutes since last user interaction

bool

overtakeService_WeAreInOverrideMode

True if launched via dual mode

byte

tempHDD

Hard Disk temperature

str

version

Client Version

_ClientStatusThread Class

class rrClient._ClientStatusThread

Information about rrClients thread activity.

Example, list if clients thread are rendering:

from rr_python_utils.load_rrlib import rrLib
import rr_python_utils.connection as rr_connect

tcp = rr_connect.server_connect()
tcp.clientGetList()

for i in range(tcp.clients.count()):
    client = tcp.clients.clientAt(i)
    status = client.status
    for j in range(status.maxJobThreads):
        jt = client.jobThread(j)
        print(f"{status.name}'s thread {j} is {'not ' if not jt.isRendering() else ''}rendering")

class _ClientStatusThread properties:

Type

Name

Description

byte

clientStatus

Status ID of the rrClient. Please see clientStatusAsStringSingle(). The IDs are listed here _ClientStatus.

float

jobCPU_Usage

CPU usage of the job.

int

jobID

ID of the job

bool

jobIsPreview

Returns true if the job in preview render state.

int

jobMemoryUsageMB

Memory usage of the job.

byte

jobMultiFrameID

Image tile index being rendered

int

jobSeqEnd

End frame of the current segment as frame number.

int

jobSeqEndJobNr

End frame of the current segment as internal job number.

int

jobSeqStart

Start frame of the current segment as frame number.

int

jobSeqStartJobNr

Start frame of the current segment as internal job number.

int

jobSeqStep

Frame step of the current segment as frame number.

int

jobSeqStepJobNr

Frame step of the current segment as internal job number

int

jobStatus

Current status of the job at the rrClient (preview, main render, post-script, …). The IDs are listed here rrJob._Status.

byte

maxCoresSetForJob

Max number of cores set for the job.

class _ClientStatusThread functions:

Return Type

Name

Description

str

clientStatusAsStringSingle()

Returns the clientStatus+jobstatus of the thread as string

bool

hasKSOLoaded()

Returns true if the thread is keeping a scene in memory.

bool

isRendering()

Returns true if the thread is rendering.

_ClientHardware Class

class rrClient._ClientHardware

Hardware settings of the render client.

Example, list clients operating system and core:

from rr_python_utils.load_rrlib import rrLib
import rr_python_utils.connection as rr_connect

tcp = rr_connect.server_connect()
tcp.clientGetList()

for i in range(tcp.clients.count()) :
    client = tcp.clients.clientAt(i)
    print(f"client {client.name()} runs {client.hw.OSasString()} and has {client.hw.coreCount} cores")

class _ClientHardware properties:

Type

Name

Description

byte

OS

Type of Operating System. 1: Windows, 2: Linux, 3: OSX

bool

OSis64

True if the machine is running a 64 bit Operating System

byte

OSversion

version of the Operating System

int

PS

Processor Speed of the client. Relative speed compared to the other clients

int

coreCount

Number of logical cores. (Physical cores x Hyperthreading = Logical Cores)

float

ghzEffective

The total Ghz of the machine. The default Hyperthreading speedup percentage is taken into account.

Note

Since different CPUs vendors (Intel, AMD) and different CPU architectures have different computation speeds at the same GHz, you should use PS

byte

gpuCount

Number of GPUs

float

hourCost

Overrides the global costs which are calculated per Ghz

int

hourWatt

Custom counter (does not require to be the Watt usage of the machine)

str

infoStr

Some inhouse custom information

bool

isCloudConnector

True if this Client is a Cloud Connector

str

locationFloor

Some inhouse custom information

int

nrCores

Number of logical cores. (Physical cores x Hyperthreading = Logical Cores)

int

totalMemoryMB

Total installed memory.

class _ClientHardware functions:

Return Type

Name

Description

str

OSasString()

OSversion and OSis64 as string

_ClientGroupList Class

class libpyRR39._ClientGroupList

Similar to libpyRR39._ClientGroupList, but loads the settings from the config files rather than from a tcp connection. Contains the client groups set in rrConfig.

Example, list all groups and their render clients:

from rr_python_utils.load_rrlib import rrLib
import rr_python_utils.connection as rr_connect

tcp = rr_connect.server_connect()
group_list = tcp.clientGetGroups()

for i in range(group_list.count):
    group = group_list.clientGroup(i)
    num_clients = group.count()

    print(f"Group {group.getName()} contains {num_clients} clients")
    for j in range(num_clients):
        print(    group.getClientName(j))

class _ClientGroupList properties:

Type

Name

Description

int

count

Get/set the number of groups

datetime.datetime

settingsFileDate

Date/Time of the group settings file loaded/saved.

class _ClientGroupList functions:

Return Type

Name

Description

_ClientGroup

clientGroup(int index)

Get client group at given index

clientGroupSet(int index, _ClientGroup group)

Replace client group at index with group.

int

clientGroupsMax()

Returns the maximum number of possible groups in this RR version

str

getError()

Returns the error message in case the loadFromFile() or SaveToFile() fails.

str

groupsOfClient(str clientName)

Returns a comma separated list of groups of which the client is a member of

_ClientGroup Class

class libpyRR39._ClientGroup

class _ClientGroup functions:

Return Type

Name

Description

addClient(str name)

Add client name to the group

str

allMemberGlobalIndices()

Returns global indices of all members of this group as a comma separated string

clear()

Remove all clients from the group

int

count()

Number of Clients in group

str

getClientName(int index)

Get client name at list index

str

getName()

Get the name of the group

bool

isMember_byGlobalIndex(int global-idx)

RR keeps a global list of all clients. This function checks if a client at index global-idx in the global list is a member of this group.

removeClient(str name)

Remove client with given name from the group

removeClientbyID(int index)

Remove client at given index from the group

setName(str name)

Set the name of the group

_ClientStatus Class

class rrClient._ClientStatus

Client Status IDs.

ID

Name

Description

0

sOff

Off

1

sFree

Free

2

sDisabled

Disabled

3

sRendering

Rendering

4

sRenderingSuccessful

Render finished successfully

5

sAborted

Job was aborted without reason

6

sCrashed

Job Crashed

7

sDisabledAllowLittle

Disabled - But allow jobs flagged as Little

8

sRenderingStarting

New job starts to render

9

sNoRenderLicense

Render application returned a license issue

10

sPermanentCrashed

Crashed with an error that de-assignes the client

11

sClientFreeze

Client app froze

12

sAbortedDisable

Job aborted - Client was disabled

13

sAbortedLowMemory

Job aborted - System memory was getting low

14

sAbortedFrozen

Job aborted - Render app froze

15

sAbortedHighUserCPU

Job aborted - High artist CPU usage

16

sAbortedFrameTime

Job aborted - Frame time limit reached

17

sAbortedWorkinghours

Job aborted - Aborted because of working hours

18

sAbortedReservedClient

Job aborted - Client is privileged for an other job type waiting at the rrServer

19

sAbortedHighPriority

Job aborted - Other job with high prio and ‘Abort lower prio jobs’ waiting at the rrServer

20

sAbortedrrControl

Job aborted - Some artist has send the the Abort command via rrControl

21

sAbortedAverage

Job aborted - Client averaging in progress. The project of this has more clients than other projects

22

sAbortedLicenseBlock

Job aborted - Some artist has requested to free a renderer license

23

sAbortedLocalMachine

Job aborted - Artist on the machine has used the Abort command

24

sAbortedProcessFound

Job aborted - Process that force an abort was found (see rrConfig)

25

sRenderingSuccessfulNoNewJob

Render finished successfully - but client does not request new job

26

sDisabledWorkinghours

Disabled because of Working Hours

27

sDisabledWorkinghoursAllowLittle

Disabled because of Working Hours - But allow jobs flagged as Little

28

sDisabledKeepDisabled

Deactivated

29

sCrashedKSOLogError

RR render script with Keep Scene Open reported an issue

30

sNoRRLicense

No Royal Render License

31

sClosingKSO

Keep Scene Open is closing old scene file

32

sIs32Bit

deprecated

33

sUnableToAbort

Windows Error Reporting locked the render process

34

sNoRRCloudLicense

No Royal Render cloud license

_ClientStatusFilter Class

class libpyRR39._ClientStatusFilter

0

All

1

Idle

2

DisabledAll

3

DisabledWH

4

DisabledIdle3h

5

Rendering

6

Offline

7

Online

_clientColumns Class

class libpyRR39._clientColumns

0

Client

1

DefaultOrder

2

Status

4

CPU_Usage

5

Available_Memory

6

OS

7

User

8

Version

9

HD_temperature

10

Memory

11

Cores

12

PS

13

Info

16

GPU_usage

17

GPU_temperature

18

GPU_available_mem

25

NetIn

26

NetOut

27

LastStatusReport

28

CPU_Name