CallbackFunction

class pyarts.arts.CallbackFunction

Used to inject custom code into Agenda

An instance of this object can be called taking only an instance of the workspace as input.

Example

>>> import pyarts
>>> def print_ws(ws):
>>>     print(ws.iy_unit.value)
>>> ws = pyarts.workspace.Workspace()
>>> cb = pyarts.arts.CallbackFunction(print_ws)
>>> cb(ws)
1

Workspace methods that can generate CallbackFunction

Workspace methods that require CallbackFunction

__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: pyarts.arts.CallbackFunction) -> None

Initialize as empty call

  1. __init__(self: pyarts.arts.CallbackFunction, arg0: Callable[[pyarts.arts._Workspace], None]) -> None

Initialize from python callable

Methods

__init__(*args, **kwargs)

Overloaded function.