API
Cython module
__file__ = '/home/docs/checkouts/readthedocs.org/user_builds/finance-dag/checkouts/latest/fdag/fast_dag.cpython-312-x86_64-linux-gnu.so'
module-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__name__ = 'fdag.fast_dag'
module-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__package__ = 'fdag'
module-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__test__ = {}
module-attribute
dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object's (key, value) pairs dict(iterable) -> new dictionary initialized as if via: d = {} for k, v in iterable: d[k] = v dict(**kwargs) -> new dictionary initialized with the name=value pairs in the keyword argument list. For example: dict(one=1, two=2)
DAGEngine
Manages the lifecycle and topology of the graph.
__doc__ = 'Manages the lifecycle and topology of the graph.'
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__pyx_vtable__ = <capsule object NULL at 0x7d49a345b420>
class-attribute
Capsule objects let you wrap a C "void *" pointer in a Python object. They're a way of passing data through the Python interpreter without creating your own custom type.
Capsules are used for communication between extension modules. They provide a way for an extension module to export a C interface to other extension modules, so that extension modules can use the Python import mechanism to link to one another.
__init__(*args, **kwargs)
method descriptor
Initialize self. See help(type(self)) for accurate signature.
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
Node
A C-level extension type representing a single node in the DAG.
__doc__ = '\n A C-level extension type representing a single node in the DAG.\n '
class-attribute
str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str
Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.
__pyx_vtable__ = <capsule object NULL at 0x7d49a2eb3720>
class-attribute
Capsule objects let you wrap a C "void *" pointer in a Python object. They're a way of passing data through the Python interpreter without creating your own custom type.
Capsules are used for communication between extension modules. They provide a way for an extension module to export a C interface to other extension modules, so that extension modules can use the Python import mechanism to link to one another.
__init__(*args, **kwargs)
method descriptor
Initialize self. See help(type(self)) for accurate signature.
__new__(*args, **kwargs)
builtin
Create and return a new object. See help(type) for accurate signature.
add_dependency(dep)
method descriptor
Creates a bidirectional edge. Prevents duplicates during dynamic access.
invalidate()
method descriptor
Fast C-level recursive invalidation. Uses bint (boolean integer) for 0-overhead checks.
Python module
ReactiveMixin
Source code in fdag/dag.py
249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 | |
invalidate(name)
Recursively marks a node and all of its dependents as invalidated, clearing them from the cache so they recalculate on the next access.
Source code in fdag/dag.py
analyze_method_dependencies_1(cls, method_name)
Analyze and return the set of attribute or method dependencies used within a given method of a class.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cls
|
type
|
The class containing the method. |
required |
method_name
|
str
|
The name of the method to analyze. |
required |
Returns:
| Name | Type | Description |
|---|---|---|
set |
set
|
A set of dependency names used in the specified method. |
Source code in fdag/dag.py
analyze_method_dependencies_2(cls, method_name)
Analyze and return the set of attribute or method dependencies used within a given method of a class.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cls
|
type
|
The class containing the method. |
required |
method_name
|
str
|
The name of the method to analyze. |
required |
Returns:
| Name | Type | Description |
|---|---|---|
set |
set
|
A set of dependency names used in the specified method. |
Source code in fdag/dag.py
apply_cache(instance, name, func)
Wraps a method to add caching, dependency tracking, and eager evaluation tied to a specific ReactiveMixin instance.