Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Capture-Recapture Models in Python with PyMC3
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Edderic
Copy link

Edderic commented Jul 11, 2019

Hey,

Thanks for this awesome tutorial! I'm planning to make use of it for calculating birth rates for whales, so thanks so much for writing this up!

I have one question. In the Jolly-Seber section, you mentioned the following:

Screenshot from 2019-07-11 09-26-01

I read the above expression as "everything other than detecting an individual who was alive in the study period" which involves scenarios where individual is alive up to the end of the study but never captured, like you said, but also involves scenarios where individual dies before the end of study. So the description "the probability that an individual is alive at the end of the study period but never captured" is not entirely correct, is it?

Loading

@AustinRochford
Copy link
Author

AustinRochford commented Jul 12, 2019

I think the probability that an individual is alive at the end of the study period but never captured" is correct - the definition of $\Psi$ includes the survival probability $\phi$.

Loading

@vaisvila
Copy link

vaisvila commented Sep 14, 2020

Hi,

I am new to Python and am trying to run the Jolly-Seber example as the building block of an analysis I want to do. I am having trouble when I try to run:

with js_model:
js_trace = pm.sample(**SAMPLE_KWARGS)

It gives me this traceback. I imagine it has to do with syntax changing since the example was produced but I am not sure how to diagnose given how new I am to python. This might be a silly problem, sorry!

Traceback (most recent call last):
File "", line 1, in
File "C:\Users\16307\anaconda3\lib\multiprocessing\spawn.py", line 116, in spawn_main
exitcode = _main(fd, parent_sentinel)
File "C:\Users\16307\anaconda3\lib\multiprocessing\spawn.py", line 126, in _main
self = reduction.pickle.load(from_parent)
AttributeError: Can't get attribute 'IncompleteMultinomial' on <module 'main' (built-in)>

EDIT: It seems that "njobs" has been deprecated in favor of "cores".

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment