-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
ENH: <Support CAR distribution with tau as a vector> #7437
Comments
] |
@anirban1990 that would correspond to a distinct core RV, similarly to how a GaussianRandomWalk can be parametrized with a scalar sigma for all timesteps, or a vector sigma for each timesteps. The PyMC implementation is currently the first, and if you pass a vector you get a batch of independent GRW variates. There is some discussion here: #5972 To allow and distinguish both cases here as well we would need to parametrize the signature of CARRV so that it is either: That would require some keyword argument like |
@ricardoV94 Thank you so much for responding to my question. Let me try monkey patching with the new signature Since this monkey patching may not be compatible with your future versions, I was wondering what a long-term solution could be. I am new to this codebase. Thanks for being patient with my questions. |
Before
After
Context for the issue:
I use CAR model with tau as a vector in uncertainty projected mapping (UPM), which is a special case of CAR. In CAR, smoothing is global, however in UPM a local smoothing is employed based on the standard deviations of the sites. UPM is a published model and has been applied to many earthquake engineering case-studies (Chakraborty and Goto, 2018; 2019, Chakraborty et al.,2024).
My transition from WinBUGS to
pymc
was successful until the pymc version 5.10.3 with monkey-patching I shared above. Given thatndims_params
has been depreciated in the signature ofCARRV
class, I am no longer able to specifytau
to be a vector.I plan to actively use
pymc
for the UPM model development going forward, and hence would request a feature that allows fortau
to be a vector. It used to be specified with the last element inndims_params
. This will remove the need for me to do monkey patching in the code and make my code more readable.You can find the working code of UPM with monkey-patching in my Github repository: https://github.com/anirban1990/UPM-Spatial-Interpolation/blob/main/Codes/3_generate_UPM.ipynb
I also attach a screenshot of the code to help you navigate to the monkey-patched line.
I would really appreciate your support in this matter.
The text was updated successfully, but these errors were encountered: