IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changes between Version 1 and Version 2 of IPP_Detection_Bitmasks


Ignore:
Timestamp:
Mar 12, 2009, 10:23:41 AM (17 years ago)
Author:
Mark Huber
Comment:

minor format

Legend:

Unmodified
Added
Removed
Modified
  • IPP_Detection_Bitmasks

    v1 v2  
    33The IPP pipeline stores some information about object in the FLAGS value in the CMF file.  These values represent  "bit masks", not standard integer values.  That is, individual bits within the value have meaning, rather than the value itself.  The bit masks for CMF files are
    44
    5 <code>
    6 <pre>
     5{{{
    76typedef enum {
    87    PM_SOURCE_MODE_DEFAULT    = 0x0000, ///<
     
    2423    PM_SOURCE_MODE_SUBTRACTED = 0x8000, ///< XXX this flag is actually only used internally (move)
    2524} pmSourceMode;
    26 </pre>
    27 </code>
     25}}}
    2826
    2927These are defined in the IPP code base in "ipp/psModules/src/objects/pmSource.h"
     
    3129If I were in charge of the Transient Classification Server and only wanted to consider objects that were single PSF-like, I might use the following bitmasks to denote bad and good objects:
    3230
    33 <code>
    34 <pre>
    35 badbitmask = PM_SOURCE_MODE_FAIL + PM_SOURCE_MODE_POOR + PM_SOURCE_MODE_SATSTAR + PM_SOURCE_MODE_BLEND +
    36 PM_SOURCE_MODE_EXTERNAL + PM_SOURCE_MODE_BADPSF + PM_SOURCE_MODE_DEFECT + PM_SOURCE_MODE_SATURATED +
    37 PM_SOURCE_MODE_CR_LIMIT + PM_SOURCE_MODE_EXT_LIMIT
     31{{{
     32badbitmask = PM_SOURCE_MODE_FAIL + PM_SOURCE_MODE_POOR + PM_SOURCE_MODE_SATSTAR +
     33PM_SOURCE_MODE_BLEND + PM_SOURCE_MODE_EXTERNAL + PM_SOURCE_MODE_BADPSF + PM_SOURCE_MODE_DEFECT +
     34PM_SOURCE_MODE_SATURATED + PM_SOURCE_MODE_CR_LIMIT + PM_SOURCE_MODE_EXT_LIMIT
    3835
    3936goodbitmask = PM_SOURCE_MODE_PSFMODEL + PM_SOURCE_MODE_FITTED
    40 </pre>
    41 </code>
     37}}}
    4238
    4339=== Intro to Bit Masks ===
     
    5147their mask value in binary and decimal:
    5248
    53 <code><pre>
     49{{{
    5450DELICIOUS       0001 => 1
    5551SPICY           0010 => 2
    5652CHEAP           0100 => 4
    5753MEAT            1000 => 8
    58 </pre></code>
     54}}}
    5955
    6056Now, some typical dishes might be:
    6157
    62 <code><pre>
     58{{{
    6359Lobster         MEAT => 1000 => 8
    6460Chicken salad   CHEAP | MEAT => 1100 => 12
     
    6662Tofu curry      SPICY | CHEAP => 0110 => 6
    6763Spaghetti       DELICIOUS | CHEAP => 0101 => 5
    68 </pre></code>
     64}}}
    6965
    7066Here, the pipe ("|") between symbols means a bitwise OR operation on the