Key points are not available for this paper at this time.
RxInfer v5. 0. 0 Diff since v4. 7. 3 This is a new major release of RxInfer with a lot of breaking changes, new features, update documentation and many more! Breaking: Addons have been renamed to annotations to match the new ReactiveMP API. This affects the infer function and related types: The addons keyword argument in infer (), batchᵢnference (), and streamingᵢnference () has been renamed to annotations. Update infer (. . . , addons = AddonLogScale () ) to infer (. . . , annotations = LogScaleAnnotations () ). In NamedTuple-based options, options = (addons =. . . , ) is now options = (annotations =. . . , ). AddonLogScale has been renamed to LogScaleAnnotations (from ReactiveMP). AddonMemory has been renamed to InputArgumentsAnnotations (from ReactiveMP). getaddons / setaddons on ReactiveMPInferenceOptions have been renamed to getannotations / setannotations. The Marginal constructor changed: Marginal (data, isₚoint, isclamped, addons) is now Marginal (data, isₚoint, isclamped) (3-arg) or Marginal (data, isₚoint, isclamped, annotationdict) with a ReactiveMP. AnnotationDict. The Marginal type no longer has a type parameter for addons (MarginalD instead of MarginalD, A). See the ReactiveMP documentation for the new annotation processor API and how to implement custom annotations. Breaking: DefaultPostprocess has been removed. The postprocess keyword in infer () now defaults to nothing, and the strategy is selected automatically based on the annotations keyword: UnpackMarginalPostprocess () when annotations is nothing (the default), and NoopPostprocess () when annotations are enabled. If you previously passed postprocess = DefaultPostprocess () explicitly, simply remove it. Custom postprocessing strategies passed via postprocess =. . . continue to work unchanged. Breaking: The callback system has been refactored to use event structs instead of dispatch with positional arguments. All callback events are now concrete structs subtyping ReactiveMP. EventE with named fields. Callbacks receive a single event object instead of positional arguments. NamedTuple/Dict callbacks: Functions now receive a single event object instead of positional args. E. g. (model, iteration) ->. . . becomes (event) -> println (event. model, event. iteration). Custom callback structs: The callbacks field of infer function now accepts custom structs that implement ReactiveMP. handleₑvent (: : MyCustomCallbacksHandler, event: : SomeEvent). ReactiveMP events: It is possible now to add callbacks to the events happening in ReactiveMP inference engine. See the documentation of ReactiveMP for the available events. StopEarlyIterationStrategy: Now receives an AfterIterationEvent instead of (model, iteration). New RxInfer-level event types: BeforeModelCreationEvent, AfterModelCreationEvent, BeforeInferenceEvent, AfterInferenceEvent, BeforeIterationEvent, AfterIterationEvent, BeforeDataUpdateEvent, AfterDataUpdateEvent, OnMarginalUpdateEvent, BeforeAutostartEvent, AfterAutostartEvent. Migration is straightforward: replace positional arguments with named field access on the event object. See the Callbacks section in the documentation for details. The callbacks argument in the infer function now accepts any custom structure that implements ReactiveMP. handleₑvent, in addition to NamedTuple and Dict. The available callbacks list now also includes ReactiveMP-level callbacks such as beforeₘessageᵣulecall, afterₘessageᵣulecall, beforeₚroductₒfₘessages, afterₚroductₒfₘessages, beforeₘarginalcomputation, afterₘarginalcomputation, and others. Breaking: beforeᵢteration and afterᵢteration callbacks now use a mutable stopᵢteration: : Bool field on the event (default false). Set event. stopᵢteration = true from a callback to halt iterations early instead of returning true. The StopEarlyIterationStrategy has been updated accordingly. Breaking: Pipeline stages and the per-node scheduler argument have been replaced by the unified ReactiveMP. AbstractStreamPostprocessor abstraction (propagated from ReactiveMP v6). The where pipeline =. . . node clause has been removed together with AbstractPipelineStage, LoggerPipelineStage, AsyncPipelineStage, ScheduleOnPipelineStage, DiscontinuePipelineStage, EmptyPipelineStage, CompositePipelineStage, applyₚipelineₛtage, and scheduleᵤpdates. The scheduler option under infer (. . . , options =. . . ) has been renamed to streamₚostprocessors and now expects a ReactiveMP. AbstractStreamPostprocessor (or nothing). To reproduce the old scheduleₒn (scheduler) behaviour, wrap the scheduler in a ReactiveMP. ScheduleOnStreamPostprocessor. The default is now nothing instead of AsapScheduler (). LoggerPipelineStage has no direct replacement — use the beforeₘessageᵣulecall / afterₘessageᵣulecall callbacks instead. options = (limitₛtackdepth = N, ) continues to work unchanged; internally it is now expanded to ReactiveMP. ScheduleOnStreamPostprocessor (RxInfer. LimitStackScheduler (N) ). The infer function now accepts a benchmark = true keyword argument that automatically merges RxInferBenchmarkCallbacks with user-provided callbacks. Benchmark results are accessible via result. model. metadata: benchmark. The infer function now accepts a trace = true keyword argument that automatically merges RxInferTraceCallbacks with user-provided callbacks. All callback events are recorded as TracedEvent and accessible via result. model. metadata: trace. Added TensorBoardLoggerExt extension: when TensorBoardLogger. jl is loaded, RxInfer. convertₜoₜensorboard (trace) exports inference trace events to TensorBoard event log files. The output directory can be specified via the outputfile keyword argument. Tests are located in test/ext/TensorBoardLoggerExt/tensorboardloggerₜests. jl. Tests are now running with TestItemRunner instead of ReTestItems infer function got a new keyword argument disableᵢnferenceₑrrorₕint that disables the inference error hint if set to true The inference error hint now can be forced to throw an error with THROWONINFERENCEERRORHINT environment variable. This is done primarily to catch errors on CI when a test prints this unintentionally (which also confuses our developers in 606). All tests or documentation examples now need to use the disableᵢnferenceₑrrorₕint if the error is intentional. Merged pull requests: 🤖 Auto-format Julia code (#609) (@github-actionsbot) 🤖 Auto-format Julia code (#610) (@github-actionsbot) Use TestItemRunner instead of ReTestItems (#611) (@bvdmitri) 🤖 Auto-format Julia code (#612) (@github-actionsbot) Integrate ReactiveMP event handler and enhance documentation (#615) (@bvdmitri) Store trace time to TracedEvent (#622) (@fonsp) Trace ID for Events (#626) (@fonsp) Refactor: rename addons to annotations (ReactiveMP v6 compatibility) (#632) (@bvdmitri) Rename traceᵢd to spanᵢd and add type parameter to RxInfer events (#634) (@bvdmitri) Revert "Refactor: rename addons to annotations (ReactiveMP v6 compatibility) " (#635) (@bvdmitri) Refactor: rename addons to annotations (ReactiveMP v6 compatibility) (#636) (@bvdmitri) Release 5 (#639) (@bvdmitri) Closed issues: Docs: documentation build prints fake error that confuses even developers (#606) TraceEvent: use type as event name? (#624)
Bagaev et al. (Thu,) studied this question.