Skip to content

Commit

Permalink
fix cvi projection after 4.4.2
Browse files Browse the repository at this point in the history
  • Loading branch information
bvdmitri committed Oct 7, 2024
1 parent f4362de commit 3674454
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "ReactiveMP"
uuid = "a194aa59-28ba-4574-a09c-4a745416d6e3"
authors = ["Dmitry Bagaev <[email protected]>", "Albert Podusenko <[email protected]>", "Bart van Erp <[email protected]>", "Ismail Senoz <[email protected]>"]
version = "4.4.2"
version = "4.4.3"

[deps]
BayesBase = "b4ee3484-f114-42fe-b91c-797d54a0c67e"
Expand Down
4 changes: 2 additions & 2 deletions ext/ReactiveMPProjectionExt/layout/cvi_projection.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import ReactiveMP:
tag,
Marginalisation,
MessageMapping,
DefferedMessage,
DeferredMessage,
with_statics,
apply_pipeline_stage,
messageout,
Expand Down Expand Up @@ -67,7 +67,7 @@ function deltafn_apply_layout(::CVIProjectionApproximationDeltaFnRuleLayout, ::V
vmessageout = combineLatest((msgs_observable, marginals_observable), PushNew())

mapping = let messagemap = MessageMapping(fform, vtag, vconstraint, msgs_names, marginal_names, meta, addons, factornode, rulefallback)
(dependencies) -> DefferedMessage(dependencies[1], dependencies[2], messagemap)
(dependencies) -> DeferredMessage(dependencies[1], dependencies[2], messagemap)
end

vmessageout = with_statics(factornode, vmessageout)
Expand Down
2 changes: 1 addition & 1 deletion src/message.jl
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ constrain_form_as_message(message::Message, form_constraint) =
Message(constrain_form(form_constraint, getdata(message)), is_clamped(message), is_initial(message), getaddons(message))

# Note: we need extra Base.Generator(as_message, messages) step here, because some of the messages might be VMP messages
# We want to cast it explicitly to a Message structure (which as_message does in case of DefferedMessage)
# We want to cast it explicitly to a Message structure (which as_message does in case of DeferredMessage)
# We use with Base.Generator to reduce an amount of memory used by this procedure since Generator generates items lazily
prod_foldl_reduce(prod_constraint, form_constraint, ::FormConstraintCheckEach) =
(messages) -> foldl((left, right) -> constrain_form_as_message(multiply_messages(prod_constraint, left, right), form_constraint), Base.Generator(as_message, messages))
Expand Down

2 comments on commit 3674454

@bvdmitri
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/116731

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v4.4.3 -m "<description of version>" 367445466f53f06384a234e802599d42b966d9ea
git push origin v4.4.3

Please sign in to comment.