Skip to content
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

adding add_statmap code #2811

Merged
merged 6 commits into from
Jul 3, 2019

Conversation

GarethCabournDavies
Copy link
Contributor

pycbc_multiifo_add_statmap code will use backgrounds of any coincidences where that detector combination is 'on'.

For example, if the foreground coincidence comes from H1L1, but V1 was also operating at the time, the background used for ifar/fap/ifar_exc/fap_exc calculation will combine backgrounds from H1L1, H1V1, L1V1 and H1L1V1

@GarethCabournDavies
Copy link
Contributor Author

GarethCabournDavies commented Jun 27, 2019

diff between this and the multiifo combine statmap may make the changes easier to see:
add_vs_combine_statmap_diff_output.txt

I will try to remember to upload again after changes, but the version on CIT will probably be updated more regularly: add_vs_combine_statmap_diff_output.txt

@tdent
Copy link
Contributor

tdent commented Jun 27, 2019

I think the appropriate test here is to print out or otherwise output the FAR values after clustering from the previous trials-factor (combine_statmap) method and from this one and check they are the same for double time and comparable (but not identical) for triple time

the gps times of the new clustered events may not be identical to the old ones but we should be able to compare one cluster with another around the same time in all or nearly all cases.

@GarethCabournDavies
Copy link
Contributor Author

The changes to the effective trials factor are as follows:
image

This is as expected for this chunk of data. The background reverse-cumulative histogram for all coincidences divided by that for only those in each coincidence is as follows (zoomed to match plot area of above), This has been divided by 4 to get the changes to the effective trials factor:
image

We see that these agree well

@tdent
Copy link
Contributor

tdent commented Jul 2, 2019

(Note that these plots are from an O2 chunk 21 run with a weird background statistic distribution due to a separate issue with the [uncombined] statmap code which is being addressed in parallel.)

@GarethCabournDavies
Copy link
Contributor Author

Updated diff of add_statmap and combine_statmap:

add_vs_combine_statmap_diff_output_20190702.txt

on CIT

@tdent
Copy link
Contributor

tdent commented Jul 2, 2019

Noting that we want to initially cluster coincs in triple time by stat (not ifar) since we believe the stat should be a better ranking between different types of coinc.
Also the assignment of the final FAR as the sum of the individual coinc type FARs at the stat value of the candidate event is appropriate for clustering on stat not ifar.

@GarethCabournDavies
Copy link
Contributor Author

GarethCabournDavies commented Jul 3, 2019

image

After latest updates, the ifar calculation is now equivalent to before (with a better comparison plot style now being used)

I believe this is ready for review now

@tdent
Copy link
Contributor

tdent commented Jul 3, 2019

@ahnitz note this is no longer WIP.

Copy link
Contributor

@tdent tdent left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mostly changes to comments, ordering etc., one significant request to make the 'available combos' calc more readable.

@tdent
Copy link
Contributor

tdent commented Jul 3, 2019

& you will want to fetch/rebase after addressing comments.

@ahnitz
Copy link
Member

ahnitz commented Jul 3, 2019

@GarethDaviesGW I haven't tried running this myself, but I've scanned through the code. I don't have any major comments. It looks to have the pieces I'd have expected to be there for what I think it's supposed to do (i.e. rerank events with a combined background).

Copy link
Member

@ahnitz ahnitz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Barring implementing @tdent's changes.

@GarethCabournDavies GarethCabournDavies merged commit d5aecea into gwastro:master Jul 3, 2019
OliverEdy pushed a commit to OliverEdy/pycbc that referenced this pull request Apr 3, 2023
* adding add_statmap code to utilise different backgrounds for ifar calculation

* Cluster over stat instead of ifar. Make the background calculation _much_ faster.

* axis needed for np sum in far calculation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants