vector distribution tests should test with vectors of not all the same values
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 839
- Forks
- 220
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 14
Description
Description
There was a bug in an lcdf distribution that would have been caught if the vectorized versions of the CDFs were tested with vectors of different values (https://github.com/stan-dev/math/issues/1662).
Right now the vectorized tests build vectors of the same value (see the repeat_as_vector test).
This would have been caught if there was a test that tested vectorized vs. non-vectorized versions of the functions where it's not just a repeat of the same value (see discussion here).
Current Version:
v3.2.0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in test/prob/test_fixture_cdf.hpp at the repeat_as_vector test and inspect how the vectorized CDF tests are built. Compare vectorized and non-vectorized results using vectors containing different values; this is done when the tests no longer only repeat one value and would expose the referenced distribution discrepancy.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- testing-qa
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100