photonpacket.frameseries module¶
-
class
photonpacket.frameseries.frameseries(photons, idxs, shape, cut=True, dtype=<class 'numpy.uint16'>)[source]¶ Bases:
objectMethods
Accumulate autocoincidences
accumframes([first, nframes])Accumulate all photons from frames ranging from first to first+nframes defaults to all frames
append(fs)Append antoher frameseries to current frameseries
copy()Copies the frameseries in memory and returns new object
cuttoshape(shape)Cut frames to shape
delneighbours([r, metric])Find photon pairs that are too close to each other and remove second photon from the frame args: radius, metric (c.f.
delsubsequent([Nf])Delete Nf frames after photon is detected in one
delsubsmask([Nf])Get the mask corresponding to delsubsequent function; does not alter the object
alias of
numpy.uint16from_dict(d)Create frameseries object from dictionary
len()Get total length fo series of frames Nframes
plot([samples])Plot the series as a time series of photon number after resampling
rescale(scale, centerpoint)Rescale coordinate system
rescalediv(factor)rescale photon positions by factor = old_div / new_div
rotate(angle, centerpoint)Rotate coordinate system
shift(n)Shift frames
store(fname)Store pickled frameseries
timeseries([samples])Get photon numbers as resampled time series
transform(transform)Affine tranformation of photons.
delframes
fs_frames
g2
imshow
maskframes
mean
std
thmodes
var
-
N= array([], dtype=float64)¶
-
Nframes= 0¶
-
accumframes(first=0, nframes='all', **kwargs)[source]¶ Accumulate all photons from frames ranging from first to first+nframes defaults to all frames
‘kwargs’ : minphotons, maxphotons (filters out frames), nphotons
- Returns
- accum
numpy.ndarray
- accum
-
delneighbours(r=5, metric='euclidean')[source]¶ Find photon pairs that are too close to each other and remove second photon from the frame args: radius, metric (c.f. scipy.spatial.distance.pdist)
-
delsubsmask(Nf=10)[source]¶ Get the mask corresponding to delsubsequent function; does not alter the object
-
dtype¶ alias of
numpy.uint16
-
classmethod
from_dict(d)[source]¶ Create frameseries object from dictionary
photons :
numpy.ndarrayidxs :
numpy.ndarrayshape : tuple
cut : bool
dtype : data-type
-
idxs= array([], dtype=float64)¶
-
photons= array([], dtype=float64)¶
-
shape= ()¶
-
-
photonpacket.frameseries.fsplot(fslist, samples=1000)[source]¶ Plot mutltiple frameseries as photon number time series
-
class
photonpacket.frameseries.singleframe(photons, idxs, shape, cut=True, dtype=<class 'numpy.uint16'>)[source]¶ Bases:
photonpacket.frameseries.frameseriesMethods
accumautocoinc()Accumulate autocoincidences
accumframes([first, nframes])Accumulate all photons from frames ranging from first to first+nframes defaults to all frames
append(fs)Append antoher frameseries to current frameseries
copy()Copies the frameseries in memory and returns new object
cuttoshape(shape)Cut frames to shape
delneighbours([r, metric])Find photon pairs that are too close to each other and remove second photon from the frame args: radius, metric (c.f.
delsubsequent([Nf])Delete Nf frames after photon is detected in one
delsubsmask([Nf])Get the mask corresponding to delsubsequent function; does not alter the object
dtypealias of
numpy.uint16from_dict(d)Create frameseries object from dictionary
len()Get total length fo series of frames Nframes
plot([samples])Plot the series as a time series of photon number after resampling
rescale(scale, centerpoint)Rescale coordinate system
rescalediv(factor)rescale photon positions by factor = old_div / new_div
rotate(angle, centerpoint)Rotate coordinate system
shift(n)Shift frames
store(fname)Store pickled frameseries
timeseries([samples])Get photon numbers as resampled time series
transform(transform)Affine tranformation of photons.
delframes
fs_frames
g2
imshow
maskframes
mean
scatter
std
thmodes
var