COMPASS  5.4.4
End-to-end AO simulation tool using GPU acceleration
sutra_centroider_maskedPix.h
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------
2 // This file is part of COMPASS <https://anr-compass.github.io/compass/>
3 //
4 // Copyright (C) 2011-2023 COMPASS Team <https://github.com/ANR-COMPASS>
5 // All rights reserved.
6 // -----------------------------------------------------------------------------
7 
15 
16 #ifndef _SUTRA_CENTROIDER_MASKEDPIX_H_
17 #define _SUTRA_CENTROIDER_MASKEDPIX_H_
18 
19 #include <sutra_centroider.h>
20 #include <sutra_wfs_pyr_pyrhr.h>
21 #include <string>
22 
23 template <class Tin, class T>
24 class SutraCentroiderMaskedPix : public SutraCentroider<Tin, T> {
25  public:
28 
29  public:
31  long nvalid, float offset,
32  float scale, bool filter_TT, int device);
33 
35 
36  string get_type();
37 
38  int get_maskedPix(float *img, float *intensities, T *centroids, int *subindx,
39  int *subindy, int ns, cudaStream_t stream=0);
40  int get_cog(float *img, float *intensities, T *centroids, int nvalid,
41  int npix, int ntot, cudaStream_t stream=0);
42  int get_cog(float *intensities, T *slopes, bool noise);
43  int get_cog();
44  int fill_selected_pix(T *pix);
45  int fill_mask();
46 };
47 
48 void fill_intensities(float *intensities, float *img, int *subindx,
49  int *subindy, int ns, int nslopes, CarmaDevice *device, cudaStream_t stream=0);
50 template <class T>
51 void get_masked_pix(T *centroids, T *ref, float *img, int *subindx, int *subindy,
52  float *psum, int ns, int nslopes, CarmaDevice *device, cudaStream_t stream=0);
53 template <class T>
54 void pyr_fill_selected_pix(T *img, int img_sizex, T *pix, int *subindx, int *subindy,
55  int nvalid, CarmaDevice *device);
56 template <class T>
57 void pyr_fill_mask(T *mask, int img_sizex, int *subindx, int *subindy,
58  int nvalid, CarmaDevice *device);
59 
60 #endif // _SUTRA_CENTROIDER_MASKEDPIX_H_
this class provides the context in which CarmaObj are created
Definition: carma_context.h:79
this class provides the centroider features to COMPASS
this class provides the centroider_maskedPix features to COMPASS
int get_cog(float *intensities, T *slopes, bool noise)
SutraCentroiderMaskedPix(CarmaContext *context, SutraWfs *wfs, long nvalid, float offset, float scale, bool filter_TT, int device)
int fill_selected_pix(T *pix)
int get_cog(float *img, float *intensities, T *centroids, int nvalid, int npix, int ntot, cudaStream_t stream=0)
int get_maskedPix(float *img, float *intensities, T *centroids, int *subindx, int *subindy, int ns, cudaStream_t stream=0)
this class provides the wfs features to COMPASS
Definition: sutra_wfs.h:35
void pyr_fill_selected_pix(T *img, int img_sizex, T *pix, int *subindx, int *subindy, int nvalid, CarmaDevice *device)
void pyr_fill_mask(T *mask, int img_sizex, int *subindx, int *subindy, int nvalid, CarmaDevice *device)
void fill_intensities(float *intensities, float *img, int *subindx, int *subindy, int ns, int nslopes, CarmaDevice *device, cudaStream_t stream=0)
void get_masked_pix(T *centroids, T *ref, float *img, int *subindx, int *subindy, float *psum, int ns, int nslopes, CarmaDevice *device, cudaStream_t stream=0)