nuke.memory

nuke.memory(cmd, value) → str or int

Get or set information about memory usage.

The value parameter is optional and is only used by some of the commands (see below).

The cmd parameter specifies what memory information to retrieve. It can be one of the following values: - info [node-name] Return a string describing current memory usage. Can optionally provide it for a specific node. - infoxml [format_bytes] [node-name] Return current memory usage as above, but in XML format. Can optionally provide if bytes should be formatted to be human readable, and also a specific node - allocator_info [format_bytes] Return current allocator usage in XML format. Can optionally provide if bytes should be formatted to be human readable - free [size] Free as much memory as possible. If a size is specified, if will stop trying to free memory when usage drops below the size. - usage Return the amount of memory currently in use. - max_usage [size] If no size is specified, returns the current size of the memory limit. If a size is given, then set this size as the memory limit. - total_ram Return the total amount of RAM. - total_vm Return the total virtual memory. - free_count [num] Get or set the free count. - new_handler_count [num] Get or set the new handler count.