Open parkerholzer opened 3 years ago
Could you expand a little on how you are setting this up and provide a more complete traceback?
Sure, I open the .py file where the parameterization, optimization starting points, and priors are defined. Then I define the function that returns the density for the user defined prior. (Is this the file where that is supposed to go???)
I did manage to get around the issue by simply adding a class to the priors.py file in the radvel code, keeping the same structure as the other existing classes.
The complete Traceback is as follows though:
Traceback (most recent call last):
File "/opt/anaconda3/bin/radvel", line 8, in
I'm glad you found a workaround, but I still would like to track this down.
Could you share density function and the line that initializes the prior?
If you have a generally-useful prior that you think should be included with the radvel package I'd be happy to look over a pull request for what you've implemented.
I'm also having a similar User-Defined Prior issue when using the command line to fit a model. I can use the command line fit function just fine but when I try to sample using mcmc I get a pickle error. I've attached my code that's causing the error that uses the example from the docs as a test. I'll try the work-around suggested above.
I'm working to put a user-defined prior on the eccentricity, but the example given in the documentation for how to do this produces an error. From the traceback, I suspect it has something to do with the TexString argument:
AttributeError: 'str' object has no attribute 'name'