module documentation

FiftyOne service utilities.

Copyright 2017-2025, Voxel51, Inc.

Function describe_process Returns a detailed description of a process.
Function find_processes_by_args Finds a process with the specified command-line arguments.
Function get_listening_tcp_ports Retrieves a list of TCP ports that the specified process is listening on.
Function normalize_wrapper_process Returns the given process, or its child if it is a wrapper processes.
Function send_ipc_message Sends a message to a process's IPCServer.
Function _is_wrapper_process Returns true if the specified process is a wrapper around a single child process with the same arguments.
def describe_process(process): (source)

Returns a detailed description of a process.

Parameters
process:psutil.Process
Returns
str
def find_processes_by_args(args): (source)

Finds a process with the specified command-line arguments.

Only processes for the current user will be returned.

Parameters
args:list[str]a list of arguments, in the order to search for
Returns
generator of psutil.Process objects
def get_listening_tcp_ports(process): (source)

Retrieves a list of TCP ports that the specified process is listening on.

Parameters
process:psutil.Processthe process to check
Returns
generator of integers
def normalize_wrapper_process(process): (source)

Returns the given process, or its child if it is a wrapper processes.

See _is_wrapper_process() for details.

Parameters
process:psutil.Process
Returns
psutil.Process
def send_ipc_message(process, message): (source)

Sends a message to a process's IPCServer.

Parameters
process:psutil.Processprocess to send the message to
message:any type
Returns
response (any type)
def _is_wrapper_process(process): (source)

Returns true if the specified process is a wrapper around a single child process with the same arguments.

This can happen on Windows when a Python subprocess is created. These processes should generally be ignored.

Parameters
process:psutil.Process
Returns
bool