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

BetaGeoBetaBinomModel Testing Speedup #1039

Merged
merged 1 commit into from
Sep 15, 2024

Conversation

ColtAllen
Copy link
Collaborator

@ColtAllen ColtAllen commented Sep 15, 2024

Description

The slow test test_model_convergence for the recently added BetaGeoBetaBinomModel takes over 90 minutes in the CI for the following reasons:

  • The discrete distributions in this model require NUTS to default to compound sampling
  • The test dataset is rather large (11k rows)

Merging #707 will make MCMC sampling 3x faster, and although the full test dataset is still required elsewhere so that tests match research results and lifetimes outputs, for this particular slow test we can get away with a smaller dataset.

test_model_convergence is now being ran on a dataframe of 1k rows sampled from the full dataset. I had to bump up the rtol from 0.1 to 0.3 so that it passes, but added a comment the test did previously pass with the full dataset.

Related Issue

Checklist

Modules affected

  • MMM
  • CLV

Type of change

  • New feature / enhancement
  • Bug fix
  • Documentation
  • Maintenance
  • Other (please specify): Tests

📚 Documentation preview 📚: https://pymc-marketing--1039.org.readthedocs.build/en/1039/

@juanitorduz juanitorduz merged commit aa5fa1d into pymc-labs:main Sep 15, 2024
12 checks passed
@juanitorduz
Copy link
Collaborator

Thanks @ColtAllen !

@ColtAllen ColtAllen deleted the bgbb_tests branch October 22, 2024 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants