Compute correlation every second in a FileDevice #38
-
|
I would like to compute the G2 curve of a file every second (G2 curve of the photons arriving on the first second, G2 curve for the photons arriving in the second second and so on...) instead of computing the G2 using all the data of the file. Is there any way to select the photons you want to analyse and compute their correlations (using the correlation class)? Thank you in advance, |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 3 replies
-
|
it is currently not possible to correlate only parts of a file. The use case however seems interesting and we will treat it as a feature suggestion. |
Beta Was this translation helpful? Give feedback.
-
|
Yes, exactly! It would be great to have some sort of identification. So the idea would be to have the option to 'add' some identification to each photon in the postprocessing of the data so you can separe the data according to the identification? |
Beta Was this translation helpful? Give feedback.
-
|
My idea would be to extend the Heralding function which allows to filter the photons. |
Beta Was this translation helpful? Give feedback.
-
|
I have also been using markers to separate data from different spatial positions or from different experimental conditions. I have always wanted to analyse this data part by part (from marker to marker) using snAPI. I have done this reading all the data using unfold class and postprocessing it using my own scripts. I imagine that this identification might also be used to get the counts between markers. |
Beta Was this translation helpful? Give feedback.
-
|
Hi @MikelElorza I made a new update: just update it with Now we have a new function to split the calculation of the g(2) in consecutive windows: I also made a script for you that: Please tell us, if this solves your problem! Best regards, |
Beta Was this translation helpful? Give feedback.
Hi @MikelElorza I made a new update:
just update it with
pip install --upgrade snAPI
Now we have a new function to split the calculation of the g(2) in consecutive windows:
https://picoquant.github.io/snAPI/snAPI.Main.html#snAPI.Main.Correlation.setSequenceMode
I also made a script for you that:
https://github.com/PicoQuant/snAPI/blob/main/demos/Demo_g2overTime.py
Comment line 11 and uncomment line 12 and it works with ptu-files.
It should also be fast enough, to calculate these g(2) windows in realtime. Only the pcolormesh plot can't handle this for long..
Please tell us, if this solves your problem!
Best regards,