Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert to using setval_and_resample! in generated_quantities #709

Merged
merged 4 commits into from
Nov 4, 2024

Conversation

torfjelde
Copy link
Member

@torfjelde torfjelde commented Nov 1, 2024

As seen in #702 , generated_quantities currently does not work as intented for models with dot-tilde in it. This is due to changes made in #555 to generated_quantities, where we started using fix instead of setval_and_resample!.

Ideally, we should be using fix for this, so the changes introduces in #555 were completely reasonable. However, fix is still somewhat lacking in support; specifically, it lacks support for .~, as outlined in #702. This PR reverts these changes as a hotfix for the resulting bugs.

@mhauru

@coveralls
Copy link

coveralls commented Nov 1, 2024

Pull Request Test Coverage Report for Build 11667880187

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • 15 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.3%) to 77.536%

Files with Coverage Reduction New Missed Lines %
src/model.jl 1 92.47%
src/threadsafe.jl 14 48.6%
Totals Coverage Status
Change from base Build 11618965820: -0.3%
Covered Lines: 3027
Relevant Lines: 3904

💛 - Coveralls

Copy link

codecov bot commented Nov 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 77.87%. Comparing base (99def88) to head (5b63b09).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #709      +/-   ##
==========================================
+ Coverage   77.73%   77.87%   +0.13%     
==========================================
  Files          30       30              
  Lines        3926     3909      -17     
==========================================
- Hits         3052     3044       -8     
+ Misses        874      865       -9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@mhauru mhauru left a comment

Choose a reason for hiding this comment

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

I'm surprised that VarNamedVector tests don't fail. Maybe they just don't hit the extension code. Anyway, I don't understand the new (old) code fully, but given that it's just reverting to previous (successful) behaviour, I'm happy to merge.

@torfjelde
Copy link
Member Author

Might be worth considering #710 before we merge this

@yebai
Copy link
Member

yebai commented Nov 1, 2024

@sunxd3 can you help review this PR since it might relate to #651?

@penelopeysm
Copy link
Member

The green tick is a relief :D, but I think we should definitely focus on #710 instead of this, as that fixes the same tests but in a better way.

@sunxd3
Copy link
Member

sunxd3 commented Nov 3, 2024

The chain of PRs all make sense to me, sorry I couldn't give an in-depth review now, but I think Penny has a really good hold on the issue here. But definitely let me know if another serious look is required.

@torfjelde
Copy link
Member Author

I'm increasingly in favour of just merging this and make a patch release. generated_quantities is currently broken (and have been for almost a week or so now), and this PR will provide a hotfix 😕

It's becoming clear that #710 requires quite a bit more effort: #710 (comment)

@mhauru
Copy link
Member

mhauru commented Nov 4, 2024

Happy with that.

@penelopeysm
Copy link
Member

penelopeysm commented Nov 4, 2024

Looking through test failures. At least one is a regression in Mooncake (compintell/Mooncake.jl#345). Not sure if any of them are really DPPL-related.

@torfjelde
Copy link
Member Author

Thanks for finding that @penelopeysm ! 👏

@penelopeysm
Copy link
Member

Can confirm that all of the errors are purely Mooncake related, so will merge manually:)

@penelopeysm penelopeysm merged commit b96e368 into master Nov 4, 2024
4 of 10 checks passed
@penelopeysm penelopeysm deleted the torfjelde/generated-quantities-bugfix branch November 4, 2024 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants