pyphi.resolve_ties.ResolutionContext#

class pyphi.resolve_ties.ResolutionContext(max_escalation_level, memo=None)[source]#

Bases: object

Per-computation context for cascade tie resolution.

Carries the entry-point function’s escalation budget and a memoization cache shared across nested cascade calls.

Parameters:
  • max_escalation_level (Literal['Existence', 'Intrinsicality', 'Information', 'Integration', 'Exclusion', 'Composition', 'Determinism'])

  • memo (dict[Any, Any] | None)

can_escalate_to(postulate)[source]#

True iff postulate is at or below max_escalation_level in the postulate order.

Parameters:

postulate (Literal['Existence', 'Intrinsicality', 'Information', 'Integration', 'Exclusion', 'Composition', 'Determinism'])

Return type:

bool

memoize(key, fn)[source]#

Return memo[key], computing via fn() if absent.

Parameters:
Return type:

V

child()[source]#

Return a child context inheriting parent budget and memo cache.

Return type:

ResolutionContext