.. _cam:

MASCDB camera-wise data
=======================================
The files *MASCdb_CAM0.parquet*,*MASCdb_CAM1.parquet*,*MASCdb_CAM2.parquet*  contain the attributes listed in the table below.

+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|       Parameter      | Units | Type     |     Long name         |     Reference / Format / Algorithm            |
+======================+=======+==========+=======================+===============================================+
|         **Global information**                                                                                  |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| datetime             |       | datetime |                       |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| campaign             |       | string   | Field campaign string |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| pix_size             | m     | float    | Pixel size            |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| n_roi                |       | int      | | # of ROIs           | | Praz et al, 2017                            |
|                      |       |          | | in raw image        | | Note: only one main ROI                     |
|                      |       |          |                       | | is considered in the descriptors            |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| cam_id               |       | int      | Camera ID: 0, 1, 2    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| roi_width            | pix   | int      | | x-size of crop of   |                                               |
|                      |       |          | | the selected ROI    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| roi_height           | pix   | int      | | y-size of  crop of  |                                               |
|                      |       |          | | the selected ROI    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| roi_centroid_X       | pix   | int      | | Centroid X coord    |                                               |
|                      |       |          | | (original image)    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| roi_centroid_X       | pix   | int      | | Centroid Y coord    |                                               |
|                      |       |          | | ( original image)   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                               **Particle size and area**                                                        |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| area                 | m^2   | float    | Particle area         | Table A1:1 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| perim                | m     | float    | Particle perimeter    | Table A1:2 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| Dmean                | m     | float    | Mean (x/y) dimension  | Table A1:3 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| Dmax                 | m     | float    | Max dimension         | Table A1:4 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| Dmax_ori             | deg   | float    | Orientation of Dmax   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| Dmax_90              | m     | float    | | Max. dimension in   | Baker and Lawson 2006                         |
|                      |       |          | | orthogonal dir.     |                                               |
|                      |       |          | | of Dmax.            |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| D90_r                |       | float    |                       |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| eq_radius            | m     | float    | Equiv. area radius    | Table A1:5 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| area_porous          | m^2   | float    | | Porous area         | Table A1:6 in Praz et al, 2017                |
|                      |       |          | | (holes removed)     |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| area_porous_r        | m^2   | float    | | Ratio area_porous   | Table A1:7 in Praz et al, 2017                |
|                      |       |          | | over area           |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                               **Elliptical approximation: fitted ellipse**                                      |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_A            | m     | float    | Major dimension       | Table A1:8 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_B            | m     | float    | Minor dimension       | Table A1:9 in Praz et al, 2017                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_area         | m^2   | float    | Area                  | Table A1:10 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_ori          | deg   | float    | Orientation           | Table A1:11 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_a_r          |       | float    | Axis ratio            | Table A1:12 in Praz et al, 2017               |
|                      |       |          | (ell_fit_A/ell_fit_B) |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_fit_ecc          |       | float    | Eccentricity          | Table A1:13 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| compactness          |       | float    | area / ell_fit_area   | Table A1:14 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|        **Elliptical approximation: inscribed ellipse (same center and orientation of fitted one)**              |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_in_A             | m     | float    | Major dimension       | Table A1:15 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_in_B             | m     | float    | Minor dimension       | Table A1:16 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_in_area          | m^2   | float    | Area                  | Table A1:17 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|         **Elliptical approximation: circumscribed ellipse (same center and orientation of fitted one)**         |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_out_A            | m     | float    | Major dimension       | Table A1:18 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_out_B            | m     | float    | Minor dimension       | Table A1:19 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| ell_out_area         | m^2   | float    | Area                  | Table A1:20 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                        **Particle shape**                                                                       |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| roundness            |       | float    | | Area /              | Table A1:30 in Praz et al, 2017               |
|                      |       |          | | circum. circle area |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| p_circ_out_r         |       | float    | | Circ. circle perim/ | Table A1:31 in Praz et al, 2017               |
|                      |       |          | |   perimeter         |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| rectangularity       |       | float    | | Area /              | Table A1:32 in Praz et al, 2017               |
|                      |       |          | | bounding box area   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| bbox_width           | m     | float    | Bounding box width    | Table A1:33 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| bbox_len             | m     | float    | Bounding box height   | Table A1:34 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| rect_perim_ratio     |       | float    | | Bounding box perim/ | Table A1:35 in Praz et al, 2017               |
|                      |       |          | | perimeter           |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| rect_aspect_ratio    |       | float    | B. box aspect ratio   | Table A1:36 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| rect_eccentricity    |       | float    | B. box eccentricity   | Table A1:37 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| solidity             |       | float    | Area/convex hull area | Table A1:38 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| convexity            |       | float    | | Convex hull perim.  | Table A1:39 in Praz et al, 2017               |
|                      |       |          | | / perimeter ratio   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hull_n_angles        |       | int      | # vertices con. hull  | Table A1:40 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| p_circ_r             |       | float    | | Perimeter/ eq. area | Table A1:41 in Praz et al, 2017               |
|                      |       |          | | circle perimeter    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| frac_dim_boxcounting |       | float    | Fractal dim. (box)    | Table A1:42 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| frac_dim_theoretical |       | float    | Fractal dim.          | | Table A1:43 in Praz et al, 2017             |
|                      |       |          |                       | | Grazioli et al, 2014                        |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| nb_holes             |       | int      | # holes inside ROI    |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                               **Morphological skeleton**                                                        |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| skel_N_ends          |       | int      | | Skeleton #  ending  | Table A1:44 in Praz et al, 2017               |
|                      |       |          | | points              |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| skel_N_junc          |       | int      | Skeleton # junctions  | Table A1:45 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| skel_perim_ratio     |       | float    | | Skeleton length /   | Table A1:46 in Praz et al, 2017               |
|                      |       |          | | perimeter           |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| skel_area_ratio      | 1/m   | float    | | Skeleton length     | Table A1:47 in Praz et al, 2017               |
|                      |       |          | | area                |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                                **Rotational symmetry**                                                          |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_P1 ... sym_P6    |       | float    | | Standardized dist.  | Table A1:49-54 in Praz et al, 2017            |
|                      |       |          | | to centroid Fourier |                                               |
|                      |       |          | | power spec. P1...P6 |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_Pmax_id          |       | int      | ID of max.  (sym_P*)  | Table A1:55 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_P6_max_ratio     |       | float    | sym_P6 / max(sym_P*)  | Table A1:56 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_mean             | pix   | float    | Mean dist. to centroid| Table A1:57 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_std              | pix   | float    | | Standard deviation  | Table A1:58 in Praz et al, 2017               |
|                      |       |          | | dist. to centroid   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| sym_std_mean_ratio   |       | float    | sym_std / sym_mean    | Table A1:59 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                       **Texture operators (for ROI/particle)**                                                  |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| intensity_mean       |       | float    | Mean pixel brightness | Table A1:60 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| intensity_max        |       | float    | Max. pixel brightness | Table A1:61 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| contrast             |       | float    | Contrast              | Table A1:62 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| intensity_std        |       | float    | std. pixel brightness | Table A1:63 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hist_entropy         |       | float    | Bright. hist. entropy | Table A1:64 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| local_std            |       | float    | | Average local (3x3) | Table A1:65 in Praz et al, 2017               |
|                      |       |          | | intensity std       |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| local_intens         |       | float    | | Average local (3x3) | Table A1:66 in Praz et al, 2017               |
|                      |       |          | | mean intensity      |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| lap_energy           |       | float    | Energy of Laplacian   | Table A1:67 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| wavs                 |       | float    | Sum of wavelet coeff. | Table A1:68 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| complexity           |       | float    | Particle complexity   | | Table A1:69 in Praz et al, 2017             |
|                      |       |          |                       | | Garrett and Yuter, 2014                     |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                                 **Haralick features**                                                           |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| har_energy           |       | float    | Haralick energy       | Table A1:70 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| har_contrast         |       | float    | Haralick contrast     | Table A1:71 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| har_corr             |       | float    | Haralick correlation  | Table A1:72 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| har_hom              |       | float    | Haralick homogeneity  | Table A1:73 in Praz et al, 2017               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                           **Riming estimation information**                                                     |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| riming_deg_level     |       | float    | | Continuous riming   |    Rc in Praz et al, 2017                     |
|                      |       |          | | degree level        |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| riming_class_id      |       | int      | | Discrete riming     | | Praz et al, 2017                            |
|                      |       |          | | degree class ID     | | 0: undefined, 1: unrimed, 2: rimed          |
|                      |       |          |                       | | 3: densely-rimed, 4: graupel-like, 5:graupel|
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| riming_class_prob    |       | float    | | Riming classif      | Praz et al, 2017                              |
|                      |       |          | | probability         |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| riming_class_name    |       | string   | | Discrete riming     | See riming_class_id                           |
|                      |       |          | | degree class name   |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                           **Melting estimation information**                                                    |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| melting_class_id     |       | int      | | Discrete melting    | | Praz et al, 2017                            |
|                      |       |          | | class ID            | | 0: dry, 1: melting                          |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| melting_prob         |       | float    | Melting probability   | | Praz et al, 2017                            |
|                      |       |          |                       | | If rounded, it yields melting_class_id      |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| melting_class_name   |       | string   | Discrete melting      | See melting_class_id                          |
|                      |       |          | class name            |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                        **Hydrometeor type estimation information**                                              |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| snowflake_class_name |       | string   | Hydrometeor           | | Praz et al, 2017                            |
|                      |       |          | class name            | | See snowflake_class_id                      |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| snowflake_class_id   |       | int      | | Hydrometeor         | | Praz et al, 2017                            |
|                      |       |          | | class id            | | 1: small_particle, 2: columnar_crystal,     |
|                      |       |          |                       | | 3: planar_crystal, 4: aggregate,            |
|                      |       |          |                       | | 5: graupel, 6: columnar_planar_combination  |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| snowflake_class_prob |       | float    | | Classification      |                                               |
|                      |       |          | | probability         |                                               |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
|                              **Human label information**                                                        |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_snowflake         |       | int      | | Human-label         | | Boolean flag. If set to 1, this  particle   |
|                      |       |          | | hydrometeor set     | | (in this CAM view) was part of the human    |
|                      |       |          |                       | | labelled training set of Praz et al, 2017   |
|                      |       |          |                       | | for hydrometeor classification              |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_snowflake_class_id|       | int      | | Human-label         | | Human-labeled snowflake_class_id            |
|                      |       |          | | hydrometeor class   | | for the training set of Praz et al, 2017    |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_melting           |       | int      | Human-label melting   | | Boolean flag. If set to 1, this  particle   |
|                      |       |          | set                   | | (in this CAM view) was part of the human    |
|                      |       |          |                       | | labelled training set of  Praz et al, 2017  |
|                      |       |          |                       | | for melting identification                  |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_melting_class_id  |       | int      | | Human-label         | | Human-labeled melting_class_id              |
|                      |       |          | | melting class       | | for the training set of Praz et al, 2017    |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_riming            |       | int      | Human-label riming    | | Boolean flag. If set to 1, this  particl    |
|                      |       |          |                       | | (in this CAM view) was part of the human    |
|                      |       |          |                       | | labelled training set of  Praz et al, 2017  |
|                      |       |          |                       | | for riming degree estimation                |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+
| hl_riming_class_id   |       | int      | | Human-label         | | Human-labeled riming_class_id               |
|                      |       |          | | riming class        | | for the training set of Praz et al, 2017    |
+----------------------+-------+----------+-----------------------+-----------------------------------------------+

References
-----------------------------------------------

- `Baker and Lawson, 2006 <https://journals.ametsoc.org/view/journals/apme/45/9/jam2398.1.xml>`_: Baker, B. & Lawson, R. P. Improvement in Determination of Ice Water Content from Two-Dimensional Particle Imagery. Part I: Image-to-Mass Relationships.J. Appl. Meteorol. Climatol.45, 1282-1290, https://doi.org/10.1175/JAM2398.1, 2006.

- `Praz et al, 2017 <https://zenodo.org/record/5578921#.YXqUeJuxVH4>`_: Praz, C., Roulet, Y.-A., and Berne, A.: Solid hydrometeor classification and riming degree estimation from pictures collected with a Multi-Angle Snowflake Camera, Atmos. Meas. Tech., 10, 1335-1357, https://doi.org/10.5194/amt-10-1335-2017, 2017.

- `Grazioli et al, 2014 <https://amt.copernicus.org/articles/7/2869/2014/amt-7-2869-2014.html>`_: Grazioli, J., Tuia, D., Monhart, S., Schneebeli, M., Raupach, T., and Berne, A.: Hydrometeor classification from two-dimensional video disdrometer data, Atmos. Meas. Tech., 7, 2869-2882, https://doi.org/10.5194/amt-7-2869-2014, 2014.

- `Garrett and Yuter, 2014 <https://agupubs.onlinelibrary.wiley.com/doi/full/10.1002/2014GL061016>`_: Garrett, T. J. & Yuter, S. E. Observed influence of riming, temperature, and turbulence on the fallspeed of solid precipitation. Geophys. Res. Lett.41, 6515-6522, https://doi.org/10.1002/2014GL061016, 2014.
