tomtag.histogram

tomtag.histogram(tagsA, tagsB, sizeA, sizeB, tcc)
build a histogram over a specified delay sweep, for each delay counting the number of identified coincidences.
  • Parameters
    • tagsA: ndarray(dtype=int)
      • timetags of the first channel.
    • tagsB: ndarray(dtype=int)
      • timetags of the second channel.
    • sizeA: int
      • number of timetags in the first channel.
    • sizeB: int
      • number of timetags in the second channel.
    • tcc: int
      • size of coincidence window, as multiple of tag precision.
    • sizeDelay: int
      • number of delays in the histogram
    • delays: ndarray(dtype:int)
      • array that spans the delay space you want to histogram over.
  • Returns
    • coincidences: list
      • An array correspoding to the delays where each entry is the number of identified coincidences when the input tags where shifted by that specific delay.

Examples

>>> import tomtag as tt
>>> import numpy as np
>>> tagsA = np.array([12,679,1289,1487])
>>> tagsB = np.array([20,409,1279,1887])
>>> tcc = 15
>>>
>>> hist = tt.histogram(tagsA, tagsB, len(tagsA), len(tagsB), tcc)