Monkeypatch sampling functions in statespace tests
The CI for pymc-extras is extremely slow. This is due to a lot of sampling being done inside the statespace tests. An easy way to speed things up is to monkey patch pm.sample to just return an idata with some dummy data.
I believe @williambdean has already implemented something of this type for the main PyMC repo.
Yes, there are options...
basic one
https://github.com/pymc-labs/pymc-marketing/blob/2a4dd0362804577b971482ea192bf5e817a8eb43/tests/conftest.py?plain=1#L128-L162
One that includes some sample_stats ( maybe not needed)
https://github.com/pymc-labs/pymc-marketing/blob/2a4dd0362804577b971482ea192bf5e817a8eb43/scripts/run_notebooks/injected.py?plain=1#L8-L36
https://github.com/pymc-devs/pymc-examples/blob/69563da49ceef589127140d3675a05b2ba4c3ae0/scripts/run_notebooks/injected.py?plain=1#L9-L69
Would be something for pymc.testing module? Maybe just the mock_sample but not the fixture. That's quite specific and small
Yes I agree. Something at the pymc level that could be used for any downstream package would be extremely welcome
This is being partially addressed (in one file) by #510 . That PR can be used as a template for how to finish the rest (it's quite easy -- just need to import the fixture from pymc.testing then add it to any test or fixture that calls pm.sample )