## Coverage Report

#### Created: 2026-04-14 20:00

next uncovered line (L), next uncovered region (R), next uncovered branch (B)

    /home/liu/actions-runner/_work/ccv/ccv/lib/ccv.h

    Line
    Count
    Source
    1
    /**********************************************************
    2
     * C-based/Cached/Core Computer Vision Library
    3
     * Liu Liu, 2010-02-01
    4
     **********************************************************/
    5
    6
    #ifndef GUARD_ccv_h
    7
    #define GUARD_ccv_h
    8
    9
    #define _WITH_GETLINE
    10
    #include <stdio.h>
    11
    #include <stdlib.h>
    12
    #include <stdarg.h>
    13
    #include <string.h>
    14
    #include <float.h>
    15
    #include <math.h>
    16
    #include <assert.h>
    17
    #if !defined(__OpenBSD__) && !defined(__FreeBSD__) && !defined(__NetBSD__)
    18
    #include <alloca.h>
    19
    #endif
    20
    21
    122k
    #define CCV_PI (3.141592653589793)
    22
    9.67M
    #define ccmalloc malloc
    23
    295k
    #define cccalloc calloc
    24
    6.78M
    #define ccrealloc realloc
    25
    7.98M
    #define ccfree free
    26
    27
    #if defined(__unix__) || (defined(__APPLE__) && defined(__MACH__))
    28
    #include <sys/param.h>
    29
    #if defined(__APPLE__) || defined(BSD) || _POSIX_C_SOURCE >= 200112L || _XOPEN_SOURCE >= 600
    30
    59.8k
    #define ccmemalign posix_memalign
    31
    #else
    32
    #define ccmemalign(memptr, alignment, size) (*memptr = memalign(alignment, size))
    33
    #endif
    34
    #else
    35
    #define ccmemalign(memptr, alignment, size) (*memptr = ccmalloc(size))
    36
    #endif
    37
    38
    // Include toll-free bridging for ccv_nnc_tensor_t
    39
    #define CCV_NNC_TENSOR_TFB (1)
    40
    #include "nnc/ccv_nnc_tfb.h"
    41
    42
    /* Doxygen will ignore these, otherwise it has problem to process warn_unused_result directly. */
    43
    #define CCV_WARN_UNUSED(x) x __attribute__((warn_unused_result))
    44
    45
    enum {
    46
      CCV_8U   = 0x01000,
    47
      CCV_32S  = 0x02000,
    48
      CCV_32F  = 0x04000,
    49
      CCV_64S  = 0x08000,
    50
      CCV_64F  = 0x10000,
    51
      CCV_16F  = 0x20000,
    52
      CCV_QX   = 0x40000, // QX is a catch-all for quantized models (anything less than or equal to 1-byte). We can still squeeze in 1 more primitive type, which probably will be 8F or BF16. (0xFF000 are for data types).
    53
      CCV_16BF = 0x80000, // The winner is BF16. Everything else can be categorized to QX part. BF16 is different enough that it deserves a separate identification.
    54
    };
    55
    56
    enum {
    57
      CCV_C1 = 0x001,
    58
      CCV_C2 = 0x002,
    59
      CCV_C3 = 0x003,
    60
      CCV_C4 = 0x004,
    61
    };
    62
    63
    static const ssize_t _ccv_get_data_type_size[] = {
    64
      -1, 1, 4,
    65
      -1, 4,
    66
      -1, -1, -1, 8,
    67
      -1, -1, -1, -1, -1, -1, -1, 8,
    68
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 2,
    69
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
    70
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 1,
    71
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
    72
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
    73
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
    74
      -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 2
    75
    };
    76
    77
    224M
    #define CCV_GET_DATA_TYPE(x) ((x696) & 0xFF000)
    78
    215M
    #define CCV_GET_DATA_TYPE_SIZE(x) _ccv_get_data_type_size[CCV_GET_DATA_TYPE(x) >> 12]
    79
    134k
    #define CCV_MAX_CHANNEL (0xFFF)
    80
    223M
    #define CCV_GET_CHANNEL(x) ((x) & 0xFFF)
    81
    3.35M
    #define CCV_GET_STEP(cols, type) (((cols) * CCV_GET_DATA_TYPE_SIZE(type) * CCV_GET_CHANNEL(type) + 3) & -4)
    82
    300k
    #define CCV_ALL_DATA_TYPE (CCV_8U | CCV_32S | CCV_32F | CCV_64S | CCV_64F | CCV_16F | CCV_QX)
    83
    84
    enum {
    85
      CCV_MATRIX_DENSE  = 0x00100000,
    86
      CCV_MATRIX_SPARSE = 0x00200000,
    87
      CCV_MATRIX_CSR    = 0x00400000,
    88
      CCV_MATRIX_CSC    = 0x00800000,
    89
    };
    90
    91
    enum {
    92
      CCV_GARBAGE       = 0x80000000, // matrix is in cache (not used by any functions)
    93
      CCV_REUSABLE      = 0x40000000, // matrix can be recycled
    94
      CCV_UNMANAGED     = 0x20000000, // matrix is allocated by user, therefore, cannot be freed by ccv_matrix_free/ccv_matrix_free_immediately
    95
      CCV_NO_DATA_ALLOC = 0x10000000, // matrix is allocated as header only, but with no data section, therefore, you have to free the data section separately
    96
      CCV_TAPE_ALLOC    = 0x08000000, // matrix is allocated on a tape.
    97
      CCV_PINNED_MEM    = 0x04000000, // matrix is pinned in CUDA.
    98
      CCV_MAPPED_MEM    = 0x02000000, // matrix is memory-mapped.
    99
    };
    100
    101
    3.13k
    #define CCV_GET_TAPE_ALLOC(type) ((type) & CCV_TAPE_ALLOC)
    102
    103
    enum {
    104
      CCV_DENSE_VECTOR  = 0x02000000,
    105
      CCV_SPARSE_VECTOR = 0x01000000,
    106
    };
    107
    108
    typedef struct {
    109
      uint8_t ifbit;
    110
      uint32_t i;
    111
    } ccv_sparse_matrix_index_t;
    112
    113
    typedef struct {
    114
      int step;
    115
      int prime_index;
    116
      uint32_t size;
    117
      uint32_t rnum;
    118
      union {
    119
        ccv_sparse_matrix_index_t* index;
    120
        ccv_numeric_data_t data;
    121
      };
    122
    } ccv_sparse_matrix_vector_t;
    123
    124
    enum {
    125
      CCV_SPARSE_ROW_MAJOR = 0x00,
    126
      CCV_SPARSE_COL_MAJOR = 0x01,
    127
    };
    128
    129
    typedef struct {
    130
      int type;
    131
      int refcount;
    132
      uint64_t sig;
    133
      int rows;
    134
      int cols;
    135
      int major;
    136
      int prime_index;
    137
      uint32_t size;
    138
      uint32_t rnum;
    139
      union {
    140
        unsigned char u8;
    141
        int i32;
    142
        float f32;
    143
        int64_t i64;
    144
        double f64;
    145
        void* p;
    146
      } tb;
    147
      ccv_sparse_matrix_index_t* index;
    148
      ccv_sparse_matrix_vector_t* vector;
    149
    } ccv_sparse_matrix_t;
    150
    151
    typedef void ccv_matrix_t;
    152
    153
    /**
    154
     * @defgroup ccv_cache cache mechanism
    155
     * This class implements a trie-based LRU cache that is then used for ccv application-wide cache in [ccv_memory.c](/lib/ccv-memory).
    156
     * @{
    157
     */
    158
    159
    typedef void(*ccv_cache_index_free_f)(void*);
    160
    161
    typedef union {
    162
      struct {
    163
        uint64_t bitmap;
    164
        uint64_t set;
    165
        uint64_t age;
    166
      } branch;
    167
      struct {
    168
        uint64_t sign;
    169
        uint64_t off;
    170
        uint64_t type;
    171
      } terminal;
    172
    } ccv_cache_index_t;
    173
    174
    typedef struct {
    175
      ccv_cache_index_t origin;
    176
      uint32_t rnum;
    177
      uint32_t age;
    178
      size_t up;
    179
      size_t size;
    180
      ccv_cache_index_free_f ffree[16];
    181
    } ccv_cache_t;
    182
    183
    /* I made it as generic as possible */
    184
    185
    /**
    186
     * Setup a cache strcture to work with.
    187
     * @param cache The allocated cache.
    188
     * @param up The upper limit of cache size in bytes.
    189
     * @param cache_types The number of cache types in this one cache instance.
    190
     * @param ffree The function that will be used to free cached object.
    191
     */
    192
    void ccv_cache_init(ccv_cache_t* cache, size_t up, int cache_types, ccv_cache_index_free_f ffree, ...);
    193
    /**
    194
     * Get an object from cache for its signature. 0 if cannot find the object.
    195
     * @param cache The cache.
    196
     * @param sign The signature.
    197
     * @param type The type of the object.
    198
     * @return The pointer to the object.
    199
     */
    200
    void* ccv_cache_get(ccv_cache_t* cache, uint64_t sign, uint8_t* type);
    201
    /**
    202
     * Put an object to cache with its signature, size, and type
    203
     * @param cache The cache.
    204
     * @param sign The signature.
    205
     * @param x The pointer to the object.
    206
     * @param size The size of the object.
    207
     * @param type The type of the object.
    208
     * @return 0 - success, 1 - replace, -1 - failure.
    209
     */
    210
    int ccv_cache_put(ccv_cache_t* cache, uint64_t sign, void* x, uint32_t size, uint8_t type);
    211
    /**
    212
     * Get an object from cache for its signature and then remove that object from the cache. 0 if cannot find the object.
    213
     * @param cache The cache.
    214
     * @param sign The signature.
    215
     * @param type The type of the object.
    216
     * @return The pointer to the object.
    217
     */
    218
    void* ccv_cache_out(ccv_cache_t* cache, uint64_t sign, uint8_t* type);
    219
    /**
    220
     * Delete an object from cache for its signature and free it.
    221
     * @param cache The cache.
    222
     * @param sign The signature.
    223
     * @return -1 if cannot find the object, otherwise return 0.
    224
     */
    225
    int ccv_cache_delete(ccv_cache_t* cache, uint64_t sign);
    226
    /**
    227
     * Clean up the cache, free all objects inside and other memory space occupied.
    228
     * @param cache The cache.
    229
     */
    230
    void ccv_cache_cleanup(ccv_cache_t* cache);
    231
    /**
    232
     * For current implementation (trie-based LRU cache), it is an alias for ccv_cache_cleanup.
    233
     * @param cache The cache.
    234
     */
    235
    void ccv_cache_close(ccv_cache_t* cache);
    236
    /** @} */
    237
    238
    /* deprecated methods, often these implemented in another way and no longer suitable for newer computer architecture */
    239
    /* 0 */
    240
    241
    typedef struct {
    242
      int type;
    243
      int refcount;
    244
      uint64_t sig;
    245
      int rows;
    246
      int cols;
    247
      int nnz;
    248
      union {
    249
        unsigned char u8;
    250
        int i32;
    251
        float f32;
    252
        int64_t i64;
    253
        double f64;
    254
        void* p;
    255
      } tb;
    256
      int* index;
    257
      int* offset;
    258
      ccv_numeric_data_t data;
    259
    } ccv_compressed_sparse_matrix_t;
    260
    261
    182M
    #define ccv_clamp(x, a, b) ({ typeof (a) _a = (a600k); typeof (b) _b = (b600k); typeof (x) _x = (x0); (_x < _a) ? _a90.4k : (182M(_x > _b)182M ? _b128k : _x182M); })
    262
    1.00G
    #define ccv_min(a, b) ({ typeof (a) _a = (a25.9M); typeof (b) _b = (b778); (_a < _b)1.00G ? _a314M : _b692M; })
    263
    1.60G
    #define ccv_max(a, b) ({ typeof (a) _a = (a600k); typeof (b) _b = (b2.00M); (_a > _b)1.60G ? _a1.19G : _b407M; })
    264
    265
    /**
    266
     * @defgroup ccv_memory memory alloc/dealloc
    267
     * @{
    268
     */
    269
    5.74M
    #define ccv_compute_dense_matrix_size(rows, cols, type) (((sizeof(ccv_dense_matrix_t) + 63) & -64) + (((cols) * CCV_GET_DATA_TYPE_SIZE(type) * CCV_GET_CHANNEL(type) + 3) & -4) * (rows))
    270
    /**
    271
     * Check the input matrix, if it is the allowed type, return it, otherwise create one with prefer_type.
    272
     * @param x The matrix to check.
    273
     * @param rows Rows of the matrix.
    274
     * @param cols Columns of the matrix.
    275
     * @param types Allowed types, it can be a mask of multiple types, e.g. CCV_8U | CCV_32S allows both 8-bit unsigned integer type and 32-bit signed integer type.
    276
     * @param prefer_type The default type, it can be only one type.
    277
     * @param sig The signature, using 0 if you don't know what it is.
    278
     * @return The returned matrix object that satisfies the requirements.
    279
     */
    280
    CCV_WARN_UNUSED(ccv_dense_matrix_t*) ccv_dense_matrix_renew(ccv_dense_matrix_t* x, int rows, int cols, int types, int prefer_type, uint64_t sig);
    281
    /**
    282
     * Create a dense matrix with rows, cols, and type.
    283
     * @param rows Rows of the matrix.
    284
     * @param cols Columns of the matrix.
    285
     * @param type Matrix supports 4 data types - CCV_8U, CCV_32S, CCV_64S, CCV_32F, CCV_64F and up to 255 channels. e.g. CCV_32F | 31 will create a matrix with float (32-bit float point) data type with 31 channels (the default type for ccv_hog).
    286
     * @param data If 0, ccv will create the matrix by allocating memory itself. Otherwise, it will use the memory region referenced by 'data'.
    287
     * @param sig The signature, using 0 if you don't know what it is.
    288
     * @return The newly created matrix object.
    289
     */
    290
    CCV_WARN_UNUSED(ccv_dense_matrix_t*) ccv_dense_matrix_new(int rows, int cols, int type, void* data, uint64_t sig);
    291
    /**
    292
     * This method will return a dense matrix allocated on stack, with a data pointer to a custom memory region.
    293
     * @param rows Rows of the matrix.
    294
     * @param cols Columns of the matrix.
    295
     * @param type The type of matrix.
    296
     * @param data The data pointer that stores the actual matrix, it cannot be 0.
    297
     * @param sig The signature, using 0 if you don't know what it is.
    298
     * @return static matrix structs.
    299
     */
    300
    ccv_dense_matrix_t ccv_dense_matrix(int rows, int cols, int type, void* data, uint64_t sig);
    301
    /**
    302
     * Mark the current matrix as mutable. Under the hood, it will set matrix signature to 0, and mark the matrix as non-collectable.
    303
     * @param mat The supplied matrix that will be marked as mutable.
    304
     */
    305
    void ccv_make_matrix_mutable(ccv_matrix_t* mat);
    306
    /**
    307
     * Mark the current matrix as immutable. Under the hood, it will generate a signature for the matrix, and mark it as non-collectable. For the convention, if the matrix is marked as immutable, you shouldn't change the content of the matrix, otherwise it will cause surprising behavior. If you want to change the content of the matrix, mark it as mutable first.
    308
     * @param mat The supplied matrix that will be marked as immutable.
    309
     **/
    310
    void ccv_make_matrix_immutable(ccv_matrix_t* mat);
    311
    /**
    312
     * Create a sparse matrix. ccv uses a double hash table for memory-efficient and quick-access sparse matrix.
    313
     * @param rows Rows of the matrix.
    314
     * @param cols Columns of the matrix.
    315
     * @param type The type of the matrix, the same as dense matrix.
    316
     * @param major Either CCV_SPARSE_ROW_MAJOR or CCV_SPARSE_COL_MAJOR, it determines the underlying data structure of the sparse matrix (either using row or column as the first-level hash table).
    317
     * @param sig The signature, using 0 if you don't know what it is.
    318
     * @return The newly created sparse matrix object.
    319
     */
    320
    CCV_WARN_UNUSED(ccv_sparse_matrix_t*) ccv_sparse_matrix_new(int rows, int cols, int type, int major, uint64_t sig);
    321
    /**
    322
     * Skip garbage-collecting process and free the matrix immediately.
    323
     * @param mat The matrix.
    324
     */
    325
    void ccv_matrix_free_immediately(ccv_matrix_t* mat);
    326
    /**
    327
     * In principal, you should always use this method to free a matrix. If you enabled cache in ccv, this method won't immediately free up memory space of the matrix. Instead, it will push the matrix to a cache if applicable so that if you want to create the same matrix again, ccv can shortcut the required matrix/image processing and return it from the cache.
    328
     * @param mat The matrix.
    329
     */
    330
    void ccv_matrix_free(ccv_matrix_t* mat);
    331
    332
    #define CCV_SPARSE_FOREACH_X(mat, block, for_block) \
    333
    6.26k
      do { \
    334
    6.26k
        uint32_t _i_, _j_; \
    335
    6.26k
        const uint32_t _size_ = (mat)->size; \
    336
    6.26k
        __attribute__((unused)) const size_t _c_ = CCV_GET_CHANNEL((mat)->type); \
    337
    6.26k
        if ((mat)->type & CCV_DENSE_VECTOR) \
    338
    6.26k
        { \
    339
    398
          for (_i_ = 0; _i_ < _size_; _i_++397) \
    340
    397
          { \
    341
    397
            ccv_sparse_matrix_index_t* const _idx_ = (mat)->index + _i_; \
    342
    397
            ccv_sparse_matrix_vector_t* const _v_ = (mat)->vector + _i_; \
    343
    397
            if (_idx_->ifbit <= 1 || !_v_->size182) \
    344
    397
              continue215; \
    345
    182k
            for (_j_ = 0; 182_j_ < _v_->size; _j_++182k) \
    346
    182k
            { \
    347
    182k
              block(_idx_->i, _j_, _j_ * _c_, _v_->data, for_block); \
    348
    182k
            } \
    349
    182
          } \
    350
    6.26k
        } else { \
    351
    6.26k
          const size_t _idx_size_ = sizeof(ccv_sparse_matrix_index_t) + ((CCV_GET_DATA_TYPE_SIZE((mat)->type) * CCV_GET_CHANNEL((mat)->type) + 3) & -4); \
    352
    67.7k
          for (_i_ = 0; _i_ < _size_; _i_++61.4k) \
    353
    61.4k
          { \
    354
    61.4k
            ccv_sparse_matrix_index_t* const _idx_ = (mat)->index + _i_; \
    355
    61.4k
            ccv_sparse_matrix_vector_t* const _v_ = (mat)->vector + _i_; \
    356
    61.4k
            if (_idx_->ifbit <= 1 || !_v_->rnum32.5k) \
    357
    61.4k
              continue28.8k; \
    358
    61.4k
            uint8_t* const _vidx_ = (uint8_t*)_v_->index; \
    359
    136k
            for (_j_ = 0; _j_ < _v_->size; _j_++104k) \
    360
    104k
            { \
    361
    104k
              ccv_sparse_matrix_index_t* const _idx_j_ = (ccv_sparse_matrix_index_t*)(_vidx_ + _idx_size_ * _j_); \
    362
    104k
              if (_idx_j_->ifbit <= 1) \
    363
    104k
                continue48.7k; \
    364
    104k
              ccv_numeric_data_t _d_ = { .u8 = (uint8_t*)(_idx_j_ + 1) }; \
    365
    55.3k
              block(_idx_->i, _idx_j_->i, 0, _d_, for_block); \
    366
    55.3k
            } \
    367
    32.5k
          } \
    368
    6.26k
        } \
    369
    6.26k
      } while (0)
    370
    0
    #define _ccv_sparse_get_32s_vector_rmj(_i_, _j_, _k_, _v_, block) block((_i_), (_j_), (_v_.i32 + (_k_)))
    371
    182k
    #define _ccv_sparse_get_32f_vector_rmj(_i_, _j_, _k_, _v_, block) block((_i_), (_j_), (_v_.f32 + (_k_)))
    372
    55.0k
    #define _ccv_sparse_get_64s_vector_rmj(_i_, _j_, _k_, _v_, block) block((_i_), (_j_), (_v_.i64 + (_k_)))
    373
    0
    #define _ccv_sparse_get_64f_vector_rmj(_i_, _j_, _k_, _v_, block) block((_i_), (_j_), (_v_.f64 + (_k_)))
    374
    0
    #define _ccv_sparse_get_8u_vector_rmj(_i_, _j_, _k_, _v_, block) block((_i_), (_j_), (_v_.u8 + (_k_)))
    375
    0
    #define _ccv_sparse_get_32s_vector_cmj(_i_, _j_, _k_, _v_, block) block((_j_), (_i_), (_v_.i32 + (_k_)))
    376
    200
    #define _ccv_sparse_get_32f_vector_cmj(_i_, _j_, _k_, _v_, block) block((_j_), (_i_), (_v_.f32 + (_k_)))
    377
    0
    #define _ccv_sparse_get_64s_vector_cmj(_i_, _j_, _k_, _v_, block) block((_j_), (_i_), (_v_.i64 + (_k_)))
    378
    0
    #define _ccv_sparse_get_64f_vector_cmj(_i_, _j_, _k_, _v_, block) block((_j_), (_i_), (_v_.f64 + (_k_)))
    379
    0
    #define _ccv_sparse_get_8u_vector_cmj(_i_, _j_, _k_, _v_, block) block((_j_), (_i_), (_v_.u8 + (_k_)))
    380
    /**
    381
     * This method enables you to loop over non-zero (or assigned) positions in a sparse matrix.
    382
     * @param mat The sparse matrix.
    383
     * @param block(row, col, value) a macro to loop over, row, col is the position (depends on if it is row major or col major), value is the typed array.
    384
     */
    385
    #define CCV_SPARSE_FOREACH(mat, block) \
    386
    6.26k
      do { if ((mat)->major & CCV_SPARSE_COL_MAJOR) { switch (1CCV_GET_DATA_TYPE1((mat)->type)) { \
    387
    0
          case CCV_32S: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_32s_vector_cmj, block); break; } \
    388
    200
          case CCV_32F: { 1CCV_SPARSE_FOREACH_X1(mat, _ccv_sparse_get_32f_vector_cmj, block); break; } \
    389
    0
          case CCV_64S: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_64s_vector_cmj, block); break; } \
    390
    0
          case CCV_64F: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_64f_vector_cmj, block); break; } \
    391
    0
          default: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_8u_vector_cmj, block); } } \
    392
    6.26k
        } else { switch (CCV_GET_DATA_TYPE((mat)->type)) { \
    393
    0
          case CCV_32S: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_32s_vector_rmj, block); break; } \
    394
    182k
          case CCV_32F: { 2CCV_SPARSE_FOREACH_X2(mat, _ccv_sparse_get_32f_vector_rmj, block); break; } \
    395
    55.0k
          case CCV_64S: { 6.26kCCV_SPARSE_FOREACH_X6.26k(mat, _ccv_sparse_get_64s_vector_rmj, block); break; } \
    396
    0
          case CCV_64F: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_64f_vector_rmj, block); break; } \
    397
    0
          default: { CCV_SPARSE_FOREACH_X(mat, _ccv_sparse_get_8u_vector_rmj, block); } } } \
    398
    6.26k
      } while (0)
    399
    400
    #define CCV_SPARSE_VECTOR_FOREACH_X(mat, vector, block, for_block) \
    401
    78.6k
      do { \
    402
    78.6k
        int _i_; \
    403
    78.6k
        __attribute__((unused)) const size_t _c_ = CCV_GET_CHANNEL((mat)->type); \
    404
    78.6k
        if ((mat)->type & CCV_DENSE_VECTOR) \
    405
    78.6k
        { \
    406
    1.00k
          for (_i_ = 0; _i_ < (vector)->size; _i_++1.00k) \
    407
    1.00k
          { \
    408
    1.00k
            block(_i_, _i_ * _c_, (vector)->data, for_block); \
    409
    1.00k
          } \
    410
    78.6k
        } else { \
    411
    78.6k
          const size_t _idx_size_ = sizeof(ccv_sparse_matrix_index_t) + ((CCV_GET_DATA_TYPE_SIZE((mat)->type) * CCV_GET_CHANNEL((mat)->type) + 3) & -4); \
    412
    78.6k
          uint8_t* const _vidx_ = (uint8_t*)(vector)->index; \
    413
    1.19M
          for (_i_ = 0; _i_ < (vector)->size; _i_++1.11M) \
    414
    1.11M
          { \
    415
    1.11M
            ccv_sparse_matrix_index_t* const _idx_i_ = (ccv_sparse_matrix_index_t*)(_vidx_ + _idx_size_ * _i_); \
    416
    1.11M
            if (_idx_i_->ifbit <= 1) \
    417
    1.11M
              continue511k; \
    418
    1.11M
            ccv_numeric_data_t _d_ = { .u8 = (uint8_t*)(_idx_i_ + 1) }; \
    419
    600k
            block(_idx_i_->i, 0, _d_, for_block); \
    420
    600k
          } \
    421
    78.6k
        } \
    422
    78.6k
      } while (0)
    423
    600k
    #define _ccv_sparse_get_32s_cell(_i_, _k_, _d_, block) block((_i_), (_d_.i32 + (_k_)))
    424
    1.04k
    #define _ccv_sparse_get_32f_cell(_i_, _k_, _d_, block) block((_i_), (_d_.f32 + (_k_)))
    425
    0
    #define _ccv_sparse_get_64s_cell(_i_, _k_, _d_, block) block((_i_), (_d_.i64 + (_k_)))
    426
    0
    #define _ccv_sparse_get_64f_cell(_i_, _k_, _d_, block) block((_i_), (_d_.f64 + (_k_)))
    427
    15
    #define _ccv_sparse_get_8u_cell(_i_, _k_, _d_, block) block((_i_), (_d_.u8 + (_k_)))
    428
    /**
    429
     * This method enables you to loop over non-zero (or assigned) positions in one vector of a sparse matrix (you can use ccv_get_sparse_matrix_vector method)
    430
     * @param mat The sparse matrix.
    431
     * @param vector The vector within the sparse matrix.
    432
     * @param block(index, value) a macro to loop over, index is the position (depends on if it is row major or col major), value is the typed array.
    433
     */
    434
    #define CCV_SPARSE_VECTOR_FOREACH(mat, vector, block) \
    435
    78.6k
      do { switch (CCV_GET_DATA_TYPE((mat)->type)) { \
    436
    600k
          case CCV_32S: { 78.5kCCV_SPARSE_VECTOR_FOREACH_X78.5k(mat, vector, _ccv_sparse_get_32s_cell, block); break; } \
    437
    1.04k
          case CCV_32F: { 2CCV_SPARSE_VECTOR_FOREACH_X2(mat, vector, _ccv_sparse_get_32f_cell, block); break; } \
    438
    0
          case CCV_64S: { CCV_SPARSE_VECTOR_FOREACH_X(mat, vector, _ccv_sparse_get_64s_cell, block); break; } \
    439
    0
          case CCV_64F: { CCV_SPARSE_VECTOR_FOREACH_X(mat, vector, _ccv_sparse_get_64f_cell, block); break; } \
    440
    15
          default: { 11CCV_SPARSE_VECTOR_FOREACH_X11(mat, vector, _ccv_sparse_get_8u_cell, block); } } \
    441
    78.6k
      } while (0)
    442
    443
    /**
    444
     * Generate a matrix signature based on input message and other signatures. This is the core method for ccv cache. In short, ccv does a given image processing by first generating an appropriate signature for that operation. It requires 1). an operation-specific message, which can be generated by concatenate the operation name and parameters. 2). the signature of input matrix(es). After that, ccv will look-up matrix in cache with the newly generated signature. If it exists, ccv will return that matrix and skip the whole operation.
    445
     * @param msg The concatenated message.
    446
     * @param len Message length.
    447
     * @param sig_start The input matrix(es) signature, end the list with 0.
    448
     * @return The generated 64-bit signature.
    449
     */
    450
    uint64_t ccv_cache_generate_signature(const char* msg, int len, uint64_t sig_start, ...);
    451
    452
    0
    #define CCV_DEFAULT_CACHE_SIZE (1024 * 1024 * 64)
    453
    454
    /**
    455
     * Drain up the cache.
    456
     */
    457
    void ccv_drain_cache(void);
    458
    /**
    459
     * Drain up and disable the application-wide cache.
    460
     */
    461
    void ccv_disable_cache(void);
    462
    /**
    463
     * Enable a application-wide cache for ccv at default memory bound (64MiB).
    464
     */
    465
    void ccv_enable_default_cache(void);
    466
    /**
    467
     * Enable a application-wide cache for ccv. The cache is bounded by given memory size.
    468
     * @param size The upper limit of the cache, in bytes.
    469
     */
    470
    void ccv_enable_cache(size_t size);
    471
    472
    #define ccv_get_dense_matrix_cell_by(type, x, row, col, ch) \
    473
    55
      (((type) & CCV_32S) ? (void*)((x)->data.i32 + ((row) * (x)->cols + (col)) * 1CCV_GET_CHANNEL1(type) + (ch)) : \
    474
    55
      (54((type) & CCV_32F)54 ? (void*)((x)->data.f32+ ((row) * (x)->cols + (col)) * 31CCV_GET_CHANNEL31(type) + (ch)) : \
    475
    54
      (23((type) & CCV_64S)23 ? (void*)((x)->data.i64+ ((row) * (x)->cols + (col)) * 0CCV_GET_CHANNEL0(type) + (ch)) : \
    476
    23
      (((type) & CCV_64F) ? (void*)((x)->data.f64 + ((row) * (x)->cols + (col)) * 5CCV_GET_CHANNEL5(type) + (ch)) : \
    477
    23
      (void*)((x)->data.u8 + (row) * (x)->step + (col) * 18CCV_GET_CHANNEL18(type) + (ch))))))
    478
    479
    55
    #define ccv_get_dense_matrix_cell(x, row, col, ch) ccv_get_dense_matrix_cell_by((x)->type, x, row, col, ch)
    480
    481
    /* this is for simplicity in code, I am sick of x->data.f64[i * x->cols + j] stuff, this is clearer, and compiler
    482
     * can optimize away the if structures */
    483
    #define ccv_get_dense_matrix_cell_value_by(type, x, row, col, ch) \
    484
    0
      (((type) & CCV_32S) ? (x)->data.i32[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
    485
    0
      (((type) & CCV_32F) ? (x)->data.f32[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
    486
    0
      (((type) & CCV_64S) ? (x)->data.i64[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
    487
    0
      (((type) & CCV_64F) ? (x)->data.f64[((row) * (x)->cols + (col)) * CCV_GET_CHANNEL(type) + (ch)] : \
    488
    0
      (x)->data.u8[(row) * (x)->step + (col) * CCV_GET_CHANNEL(type) + (ch)]))))
    489
    490
    0
    #define ccv_get_dense_matrix_cell_value(x, row, col, ch) ccv_get_dense_matrix_cell_value_by((x)->type, x, row, col, ch)
    491
    492
    #define ccv_get_value(type, ptr, i) \
    493
    882
      (((type) & CCV_32S) ? ((int*)(ptr))[(i)]0 : \
    494
    882
      (((type) & CCV_32F) ? ((float*)(ptr))[(i)]0 : \
    495
    882
      (((type) & CCV_64S) ? ((int64_t*)(ptr))[(i)]0 : \
    496
    882
      (((type) & CCV_64F) ? ((double*)(ptr))[(i)] : \
    497
    882
      ((unsigned char*)(ptr))[(i)]0))))
    498
    499
    338
    #define ccv_set_value(type, ptr, i, value, factor) switch (CCV_GET_DATA_TYPE((type))) { \
    500
    0
      case CCV_32S: ((int*)(ptr))[(i)] = (int)(value) >> factor; break; \
    501
    0
      case CCV_32F: ((float*)(ptr))[(i)] = (float)value; break; \
    502
    0
      case CCV_64S: ((int64_t*)(ptr))[(i)] = (int64_t)(value) >> factor; break; \
    503
    5.24k
      case CCV_64F: ((double*)(ptr))[(i)] = (double)338value; break; \
    504
    0
      default: ((unsigned char*)(ptr))[(i)] = ccv_clamp((int)(value) >> factor, 0, 255); }
    505
    /** @} */
    506
    507
    /**
    508
     * @defgroup ccv_io basic IO utilities
    509
     * @{
    510
     */
    511
    512
    enum {
    513
      // modifier for converting to gray-scale
    514
      CCV_IO_GRAY      = 0x100,
    515
      // modifier for converting to color
    516
      CCV_IO_RGB_COLOR = 0x300,
    517
    };
    518
    519
    enum {
    520
      // modifier for not copy the data over when read raw in-memory data
    521
      CCV_IO_NO_COPY = 0x10000,
    522
    };
    523
    524
    enum {
    525
      // read self-describe in-memory data
    526
      CCV_IO_ANY_STREAM     = 0x010,
    527
      CCV_IO_BMP_STREAM     = 0x011,
    528
      CCV_IO_JPEG_STREAM    = 0x012,
    529
      CCV_IO_PNG_STREAM     = 0x013,
    530
      CCV_IO_PLAIN_STREAM   = 0x014,
    531
      CCV_IO_DEFLATE_STREAM = 0x015,
    532
      // read self-describe on-disk data
    533
      CCV_IO_ANY_FILE       = 0x020,
    534
      CCV_IO_BMP_FILE       = 0x021,
    535
      CCV_IO_JPEG_FILE      = 0x022,
    536
      CCV_IO_PNG_FILE       = 0x023,
    537
      CCV_IO_BINARY_FILE    = 0x024,
    538
      // read not-self-describe in-memory data (a.k.a. raw data)
    539
      // you need to specify rows, cols, or scanline for these data
    540
      CCV_IO_ANY_RAW        = 0x040,
    541
      CCV_IO_RGB_RAW        = 0x041,
    542
      CCV_IO_RGBA_RAW       = 0x042,
    543
      CCV_IO_ARGB_RAW       = 0x043,
    544
      CCV_IO_BGR_RAW        = 0x044,
    545
      CCV_IO_BGRA_RAW       = 0x045,
    546
      CCV_IO_ABGR_RAW       = 0x046,
    547
      CCV_IO_GRAY_RAW       = 0x047,
    548
    };
    549
    550
    enum {
    551
      CCV_IO_FINAL = 0x00,
    552
      CCV_IO_CONTINUE,
    553
      CCV_IO_ERROR,
    554
      CCV_IO_ATTEMPTED,
    555
      CCV_IO_UNKNOWN,
    556
    };
    557
    558
    /**
    559
     * @file ccv_doxygen.h
    560
     * @fn int ccv_read(const char* in, ccv_dense_matrix_t** x, int type)
    561
     * Read image from a file. This function has soft dependencies on [LibJPEG](http://libjpeg.sourceforge.net/) and [LibPNG](http://www.libpng.org/pub/png/libpng.html). No these libraries, no JPEG nor PNG read support. However, ccv does support BMP read natively (it is a simple format after all).
    562
     * @param in The file name.
    563
     * @param x The output image.
    564
     * @param type CCV_IO_ANY_FILE, accept any file format. CCV_IO_GRAY, convert to grayscale image. CCV_IO_RGB_COLOR, convert to color image.
    565
     */
    566
    /**
    567
     * @fn int ccv_read(const void* data, ccv_dense_matrix_t** x, int type, int size)
    568
     * Read image from a a region of memory that conforms a specific image format. This function has soft dependencies on [LibJPEG](http://libjpeg.sourceforge.net/) and [LibPNG](http://www.libpng.org/pub/png/libpng.html). No these libraries, no JPEG nor PNG read support. However, ccv does support BMP read natively (it is a simple format after all).
    569
     * @param data The data memory.
    570
     * @param x The output image.
    571
     * @param type CCV_IO_ANY_STREAM, accept any file format. CCV_IO_GRAY, convert to grayscale image. CCV_IO_RGB_COLOR, convert to color image.
    572
     * @param size The size of that data memory region.
    573
     */
    574
    /**
    575
     * @fn int ccv_read(const void* data, ccv_dense_matrix_t** x, int type, int rows, int cols, int scanline)
    576
     * Read image from a region of memory that assumes specific layout (RGB, GRAY, BGR, RGBA, ARGB, RGBA, ABGR, BGRA). By default, this method will create a matrix and copy data over to that matrix. With CCV_IO_NO_COPY, it will create a matrix that has data block pointing to the original data memory region. It is your responsibility to release that data memory at an appropriate time after release the matrix.
    577
     * @param data The data memory.
    578
     * @param x The output image.
    579
     * @param type CCV_IO_ANY_RAW, CCV_IO_RGB_RAW, CCV_IO_BGR_RAW, CCV_IO_RGBA_RAW, CCV_IO_ARGB_RAW, CCV_IO_BGRA_RAW, CCV_IO_ABGR_RAW, CCV_IO_GRAY_RAW. These in conjunction can be used with CCV_IO_NO_COPY.
    580
     * @param rows How many rows in the given data memory region.
    581
     * @param cols How many columns in the given data memory region.
    582
     * @param scanline The size of a single column in the given data memory region (or known as "bytes per row").
    583
     */
    584
    int ccv_read_impl(const void* in, ccv_dense_matrix_t** x, int type, int rows, int cols, int scanline);
    585
    #define ccv_read_n(in, x, type, rows, cols, scanline, ...) \
    586
    106
      ccv_read_impl(in, x, type, rows, cols, scanline)
    587
    #define ccv_read(in, x, type, ...) \
    588
    106
      ccv_read_n(in, x, type, ##__VA_ARGS__, 0, 0, 0)
    589
    // this is a way to implement function-signature based dispatch, you can call either
    590
    // ccv_read(in, x, type) or ccv_read(in, x, type, rows, cols, scanline)
    591
    // notice that you can implement this with va_* functions, but that is not type-safe
    592
    /**
    593
     * Write image to a file. This function has soft dependencies on [LibJPEG](http://libjpeg.sourceforge.net/) and [LibPNG](http://www.libpng.org/pub/png/libpng.html). No these libraries, no JPEG nor PNG write support.
    594
     * @param mat The input image.
    595
     * @param out The file name.
    596
     * @param len The output bytes.
    597
     * @param type CCV_IO_PNG_FILE, save to PNG format. CCV_IO_JPEG_FILE, save to JPEG format.
    598
     * @param conf configuration.
    599
     */
    600
    int ccv_write(ccv_dense_matrix_t* mat, char* out, size_t* len, int type, void* conf);
    601
    /** @} */
    602
    603
    /**
    604
     * @defgroup ccv_algebra linear algebra
    605
     * @{
    606
     */
    607
    608
    double ccv_trace(ccv_matrix_t* mat);
    609
    610
    enum {
    611
      CCV_L1_NORM  = 0x01, // |dx| + |dy|
    612
      CCV_L2_NORM  = 0x02, // sqrt(dx^2 + dy^2)
    613
      CCV_GSEDT    = 0x04, // Generalized Squared Euclidean Distance Transform:
    614
                 // a * dx + b * dy + c * dx^2 + d * dy^2, when combined with CCV_L1_NORM:
    615
                 // a * |dx| + b * |dy| + c * dx^2 + d * dy^2
    616
      CCV_NEGATIVE = 0x08, // negative distance computation (from positive (min) to negative (max))
    617
      CCV_POSITIVE = 0x00, // positive distance computation (the default)
    618
    };
    619
    620
    enum {
    621
      CCV_NO_PADDING = 0x00,
    622
      CCV_PADDING_ZERO = 0x01,
    623
      CCV_PADDING_EXTEND = 0x02,
    624
      CCV_PADDING_MIRROR = 0x04,
    625
    };
    626
    627
    enum {
    628
      CCV_SIGNED = 0x00,
    629
      CCV_UNSIGNED = 0x01,
    630
    };
    631
    632
    double ccv_norm(ccv_matrix_t* mat, int type);
    633
    /**
    634
     * Normalize a matrix and return the normalize factor.
    635
     * @param a The input matrix.
    636
     * @param b The output matrix.
    637
     * @param btype The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    638
     * @param flag CCV_L1 or CCV_L2, for L1 or L2 normalization.
    639
     * @return L1 or L2 sum.
    640
     */
    641
    double ccv_normalize(ccv_matrix_t* a, ccv_matrix_t** b, int btype, int flag);
    642
    /**
    643
     * Generate the [Summed Area Table](https://en.wikipedia.org/wiki/Summed_area_table).
    644
     * @param a The input matrix.
    645
     * @param b The output matrix.
    646
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    647
     * @param padding_pattern CCV_NO_PADDING - the first row and the first column in the output matrix is the same as the input matrix. CCV_PADDING_ZERO - the first row and the first column in the output matrix is zero, thus, the output matrix size is 1 larger than the input matrix.
    648
     */
    649
    void ccv_sat(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int padding_pattern);
    650
    /**
    651
     * Dot product of two matrix.
    652
     * @param a The input matrix.
    653
     * @param b The other input matrix.
    654
     * @return Dot product.
    655
     */
    656
    double ccv_dot(ccv_matrix_t* a, ccv_matrix_t* b);
    657
    /**
    658
     * Return the sum of all elements in the matrix.
    659
     * @param mat The input matrix.
    660
     * @param flag CCV_UNSIGNED - compute fabs(x) of the elements first and then sum up. CCV_SIGNED - compute the sum normally.
    661
     */
    662
    double ccv_sum(ccv_matrix_t* mat, int flag);
    663
    /**
    664
     * Return the sum of all elements in the matrix.
    665
     * @param mat The input matrix.
    666
     * @return Element variance of the input matrix.
    667
     */
    668
    double ccv_variance(ccv_matrix_t* mat);
    669
    /**
    670
     * Do element-wise matrix multiplication.
    671
     * @param a The input matrix.
    672
     * @param b The input matrix.
    673
     * @param c The output matrix.
    674
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    675
     */
    676
    void ccv_multiply(ccv_matrix_t* a, ccv_matrix_t* b, ccv_matrix_t** c, int type);
    677
    /**
    678
     * Matrix addition.
    679
     * @param a The input matrix.
    680
     * @param b The input matrix.
    681
     * @param c The output matrix.
    682
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    683
     */
    684
    void ccv_add(ccv_matrix_t* a, ccv_matrix_t* b, ccv_matrix_t** c, int type);
    685
    /**
    686
     * Matrix subtraction.
    687
     * @param a The input matrix.
    688
     * @param b The input matrix.
    689
     * @param c The output matrix.
    690
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    691
     */
    692
    void ccv_subtract(ccv_matrix_t* a, ccv_matrix_t* b, ccv_matrix_t** c, int type);
    693
    /**
    694
     * Scale given matrix by factor of **ds**.
    695
     * @param a The input matrix.
    696
     * @param b The output matrix.
    697
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    698
     * @param ds The scale factor, `b = a * ds`
    699
     */
    700
    void ccv_scale(ccv_matrix_t* a, ccv_matrix_t** b, int type, double ds);
    701
    702
    enum {
    703
      CCV_A_TRANSPOSE = 0x01,
    704
      CCV_B_TRANSPOSE = 0X02,
    705
      CCV_C_TRANSPOSE = 0X04,
    706
    };
    707
    708
    /**
    709
     * General purpose matrix multiplication. This function has a hard dependency on [cblas](http://www.netlib.org/blas/) library.
    710
     *
    711
     * As general as it is, it computes:
    712
     *
    713
     *   alpha * A * B + beta * C
    714
     *
    715
     * whereas A, B, C are matrix, and alpha, beta are scalar.
    716
     *
    717
     * @param a The input matrix.
    718
     * @param b The input matrix.
    719
     * @param alpha The multiplication factor.
    720
     * @param c The input matrix.
    721
     * @param beta The multiplication factor.
    722
     * @param transpose CCV_A_TRANSPOSE, CCV_B_TRANSPOSE to indicate if matrix A or B need to be transposed first before multiplication.
    723
     * @param d The output matrix.
    724
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    725
     */
    726
    void ccv_gemm(ccv_matrix_t* a, ccv_matrix_t* b, double alpha, ccv_matrix_t* c, double beta, int transpose, ccv_matrix_t** d, int type);
    727
    /** @} */
    728
    729
    typedef struct {
    730
      int left;
    731
      int top;
    732
      int right;
    733
      int bottom;
    734
    } ccv_margin_t;
    735
    736
    inline static ccv_margin_t ccv_margin(int left, int top, int right, int bottom)
    737
    1
    {
    738
    1
      ccv_margin_t margin;
    739
    1
      margin.left = left;
    740
    1
      margin.top = top;
    741
    1
      margin.right = right;
    742
    1
      margin.bottom = bottom;
    743
    1
      return margin;
    744
    1
    }
    Unexecuted instantiation: adam.tests.c:ccv_margin
    Unexecuted instantiation: cifar.tests.c:ccv_margin
    Unexecuted instantiation: cnnp.core.tests.c:ccv_margin
    Unexecuted instantiation: compare.tests.c:ccv_margin
    Unexecuted instantiation: compression.tests.c:ccv_margin
    Unexecuted instantiation: concat.tests.c:ccv_margin
    Unexecuted instantiation: cublas.tests.c:ccv_margin
    Unexecuted instantiation: cudnn.tests.c:ccv_margin
    Unexecuted instantiation: datatype.tests.c:ccv_margin
    Unexecuted instantiation: dense.net.tests.c:ccv_margin
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_margin
    Unexecuted instantiation: gelu.tests.c:ccv_margin
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_margin
    Unexecuted instantiation: imdb.tests.c:ccv_margin
    Unexecuted instantiation: index.tests.c:ccv_margin
    Unexecuted instantiation: lamb.tests.c:ccv_margin
    Unexecuted instantiation: leaky_relu.tests.c:ccv_margin
    Unexecuted instantiation: loss.tests.c:ccv_margin
    Unexecuted instantiation: lstm.tests.c:ccv_margin
    Unexecuted instantiation: mpsblas.tests.c:ccv_margin
    Unexecuted instantiation: mpsdnn.tests.c:ccv_margin
    Unexecuted instantiation: nccl.tests.c:ccv_margin
    Unexecuted instantiation: nms.tests.c:ccv_margin
    Unexecuted instantiation: pad.tests.c:ccv_margin
    Unexecuted instantiation: palettize.tests.c:ccv_margin
    Unexecuted instantiation: parallel.tests.c:ccv_margin
    Unexecuted instantiation: partition.tests.c:ccv_margin
    Unexecuted instantiation: random.tests.c:ccv_margin
    Unexecuted instantiation: reduce.tests.c:ccv_margin
    Unexecuted instantiation: rmsprop.tests.c:ccv_margin
    Unexecuted instantiation: roi_align.tests.c:ccv_margin
    Unexecuted instantiation: scatter_add.tests.c:ccv_margin
    Unexecuted instantiation: schedule.tests.c:ccv_margin
    Unexecuted instantiation: sgd.tests.c:ccv_margin
    Unexecuted instantiation: smooth_l1.tests.c:ccv_margin
    Unexecuted instantiation: sort.tests.c:ccv_margin
    Unexecuted instantiation: swish.tests.c:ccv_margin
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_margin
    Unexecuted instantiation: tensor.tests.c:ccv_margin
    Unexecuted instantiation: transform.tests.c:ccv_margin
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_margin
    Unexecuted instantiation: upsample.tests.c:ccv_margin
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_margin
    Unexecuted instantiation: 3rdparty.tests.c:ccv_margin
    Unexecuted instantiation: algebra.tests.c:ccv_margin
    Unexecuted instantiation: basic.tests.c:ccv_margin
    Unexecuted instantiation: convnet.tests.c:ccv_margin
    Unexecuted instantiation: image_processing.tests.c:ccv_margin
    Unexecuted instantiation: io.tests.c:ccv_margin
    Unexecuted instantiation: memory.tests.c:ccv_margin
    Unexecuted instantiation: attention.tests.c:ccv_margin
    Unexecuted instantiation: autograd.tests.c:ccv_margin
    Unexecuted instantiation: autograd.vector.tests.c:ccv_margin
    Unexecuted instantiation: backward.tests.c:ccv_margin
    Unexecuted instantiation: batch.norm.tests.c:ccv_margin
    Unexecuted instantiation: broadcast.tests.c:ccv_margin
    Unexecuted instantiation: case_of.backward.tests.c:ccv_margin
    Unexecuted instantiation: case_of.tests.c:ccv_margin
    Unexecuted instantiation: cblas.tests.c:ccv_margin
    Unexecuted instantiation: complex.tests.c:ccv_margin
    Unexecuted instantiation: crossentropy.tests.c:ccv_margin
    Unexecuted instantiation: custom.tests.c:ccv_margin
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_margin
    Unexecuted instantiation: dataframe.tests.c:ccv_margin
    Unexecuted instantiation: dropout.tests.c:ccv_margin
    Unexecuted instantiation: forward.tests.c:ccv_margin
    Unexecuted instantiation: gemm.tests.c:ccv_margin
    Unexecuted instantiation: gradient.tests.c:ccv_margin
    Unexecuted instantiation: graph.io.tests.c:ccv_margin
    Unexecuted instantiation: graph.tests.c:ccv_margin
    Unexecuted instantiation: group.norm.tests.c:ccv_margin
    Unexecuted instantiation: histogram.tests.c:ccv_margin
    Unexecuted instantiation: layer.norm.tests.c:ccv_margin
    Unexecuted instantiation: micro.tests.c:ccv_margin
    Unexecuted instantiation: minimize.tests.c:ccv_margin
    Unexecuted instantiation: numa.tests.c:ccv_margin
    Unexecuted instantiation: rand.tests.c:ccv_margin
    Unexecuted instantiation: rmsnorm.tests.c:ccv_margin
    Unexecuted instantiation: simplify.tests.c:ccv_margin
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_margin
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_margin
    Unexecuted instantiation: tape.tests.c:ccv_margin
    Unexecuted instantiation: tensor.bind.tests.c:ccv_margin
    Unexecuted instantiation: tfb.tests.c:ccv_margin
    Unexecuted instantiation: while.backward.tests.c:ccv_margin
    Unexecuted instantiation: while.tests.c:ccv_margin
    Unexecuted instantiation: winograd.tests.c:ccv_margin
    Unexecuted instantiation: numeric.tests.c:ccv_margin
    Unexecuted instantiation: output.tests.c:ccv_margin

    util.tests.c:ccv_margin

    Line
    Count
    Source
    737
    1
    {
    738
    1
      ccv_margin_t margin;
    739
    1
      margin.left = left;
    740
    1
      margin.top = top;
    741
    1
      margin.right = right;
    742
    1
      margin.bottom = bottom;
    743
    1
      return margin;
    744
    1
    }
    Unexecuted instantiation: ccv_cache.c:ccv_margin
    Unexecuted instantiation: ccv_memory.c:ccv_margin
    Unexecuted instantiation: ccv_io.c:ccv_margin
    Unexecuted instantiation: ccv_numeric.c:ccv_margin
    Unexecuted instantiation: ccv_algebra.c:ccv_margin
    Unexecuted instantiation: ccv_util.c:ccv_margin
    Unexecuted instantiation: ccv_basic.c:ccv_margin
    Unexecuted instantiation: ccv_image_processing.c:ccv_margin
    Unexecuted instantiation: ccv_resample.c:ccv_margin
    Unexecuted instantiation: ccv_transform.c:ccv_margin
    Unexecuted instantiation: ccv_classic.c:ccv_margin
    Unexecuted instantiation: ccv_convnet.c:ccv_margin
    Unexecuted instantiation: ccv_output.c:ccv_margin
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_margin
    Unexecuted instantiation: co.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_margin
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_margin
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_margin
    Unexecuted instantiation: ccv_nnc_util.c:ccv_margin
    745
    746
    /* matrix build blocks / utility functions ccv_util.c */
    747
    /**
    748
     * @defgroup ccv_util data structure utilities
    749
     * @{
    750
     */
    751
    752
    /**
    753
     * Check and get dense matrix from general matrix structure.
    754
     * @param mat A general matrix.
    755
     */
    756
    ccv_dense_matrix_t* ccv_get_dense_matrix(ccv_matrix_t* mat);
    757
    /**
    758
     * Check and get sparse matrix from general matrix structure.
    759
     * @param mat A general matrix.
    760
     */
    761
    ccv_sparse_matrix_t* ccv_get_sparse_matrix(ccv_matrix_t* mat);
    762
    /**
    763
     * Get vector for a sparse matrix.
    764
     * @param mat The sparse matrix.
    765
     * @param index The index of that vector.
    766
     */
    767
    ccv_sparse_matrix_vector_t* ccv_get_sparse_matrix_vector(const ccv_sparse_matrix_t* mat, int index);
    768
    /**
    769
     * Get cell for a vector of a sparse matrix.
    770
     * @param mat The sparse matrix.
    771
     * @param vector The vector.
    772
     * @param index The index of the cell.
    773
     */
    774
    ccv_numeric_data_t ccv_get_sparse_matrix_cell_from_vector(const ccv_sparse_matrix_t* mat, ccv_sparse_matrix_vector_t* vector, int index);
    775
    /**
    776
     * Get cell from a sparse matrix.
    777
     * @param mat The sparse matrix.
    778
     * @param row The row index.
    779
     * @param col The column index.
    780
     */
    781
    ccv_numeric_data_t ccv_get_sparse_matrix_cell(const ccv_sparse_matrix_t* mat, int row, int col);
    782
    /**
    783
     * Set cell for a sparse matrix.
    784
     * @param mat The sparse matrix.
    785
     * @param row The row index.
    786
     * @param col The column index.
    787
     * @param data The data pointer.
    788
     */
    789
    void ccv_set_sparse_matrix_cell(ccv_sparse_matrix_t* mat, int row, int col, const void* data);
    790
    /**
    791
     * Set cell for a vector of a sparse matrix.
    792
     * @param mat The sparse matrix.
    793
     * @param vector The vector.
    794
     * @param vidx The index of the vector.
    795
     * @param data The data pointer.
    796
     */
    797
    void ccv_set_sparse_matrix_cell_from_vector(ccv_sparse_matrix_t* mat, ccv_sparse_matrix_vector_t* const vector, int vidx, const void* data);
    798
    /**
    799
     * Transform a sparse matrix into compressed representation.
    800
     * @param mat The sparse matrix.
    801
     * @param csm The compressed matrix.
    802
     */
    803
    void ccv_compress_sparse_matrix(const ccv_sparse_matrix_t* mat, ccv_compressed_sparse_matrix_t** csm);
    804
    /**
    805
     * Transform a compressed matrix into a sparse matrix.
    806
     * @param csm The compressed matrix.
    807
     * @param smt The sparse matrix.
    808
     */
    809
    void ccv_decompress_sparse_matrix(const ccv_compressed_sparse_matrix_t* csm, ccv_sparse_matrix_t** smt);
    810
    /**
    811
     * Offset input matrix by x, y.
    812
     * @param a The input matrix.
    813
     * @param b The output matrix.
    814
     * @param btype The type of output matrix, if 0, ccv will use the input matrix type.
    815
     * @param y b(0, 0) = a(x, y).
    816
     * @param x b(0, 0) = a(x, y).
    817
     */
    818
    void ccv_move(ccv_matrix_t* a, ccv_matrix_t** b, int btype, int y, int x);
    819
    /**
    820
     * Compare if two matrix are equal (with type). Return 0 if it is.
    821
     * @param a The input matrix a.
    822
     * @param b The input matrix b.
    823
     */
    824
    int ccv_matrix_eq(ccv_matrix_t* a, ccv_matrix_t* b);
    825
    /**
    826
     * Slice an input matrix given x, y and row, column size.
    827
     * @param a The input matrix.
    828
     * @param b The output matrix.
    829
     * @param btype The type of output matrix, if 0, ccv will use the input matrix type.
    830
     * @param y y coordinate.
    831
     * @param x x coordinate.
    832
     * @param rows Row size of targeted matrix.
    833
     * @param cols Column size of targeted matrix.
    834
     */
    835
    void ccv_slice(ccv_matrix_t* a, ccv_matrix_t** b, int btype, int y, int x, int rows, int cols);
    836
    /**
    837
     * Add border to the input matrix.
    838
     * @param a The input matrix.
    839
     * @param b The output matrix.
    840
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    841
     * @param margin Left, top, right, bottom width for the border.
    842
     */
    843
    void ccv_border(ccv_matrix_t* a, ccv_matrix_t** b, int type, ccv_margin_t margin);
    844
    /**
    845
     * Convert a input matrix into a matrix within visual range, so that one can output it into PNG file for inspection.
    846
     * @param a The input matrix.
    847
     * @param b The output matrix.
    848
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    849
     */
    850
    void ccv_visualize(ccv_matrix_t* a, ccv_matrix_t** b, int type);
    851
    /**
    852
     * If a given matrix has multiple channels, this function will compute a new matrix that each cell in the new matrix is the sum of all channels in the same cell of the given matrix.
    853
     * @param a The input matrix.
    854
     * @param b The output matrix.
    855
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    856
     * @param flag ccv reserved this for now.
    857
     */
    858
    void ccv_flatten(ccv_matrix_t* a, ccv_matrix_t** b, int type, int flag);
    859
    /**
    860
     * Zero out a given matrix.
    861
     * @param mat The given matrix.
    862
     */
    863
    void ccv_zero(ccv_matrix_t* mat);
    864
    /**
    865
     * Compute a new matrix that each element is first left shifted and then right shifted.
    866
     * @param a The input matrix.
    867
     * @param b The output matrix.
    868
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    869
     * @param lr Left shift amount.
    870
     * @param rr Right shift amount.
    871
     */
    872
    void ccv_shift(ccv_matrix_t* a, ccv_matrix_t** b, int type, int lr, int rr);
    873
    /**
    874
     * Check if any nan value in the given matrix, and return its position.
    875
     * @param a The given matrix.
    876
     */
    877
    int ccv_any_nan(ccv_matrix_t *a);
    878
    /**
    879
     * Return a temporary ccv_dense_matrix_t matrix that is pointing to a given matrix data section but with different rows and cols. Useful to use part of the given matrix do computations without paying memory copy performance penalty.
    880
     * @param a The given matrix.
    881
     * @param y The y offset to the given matrix.
    882
     * @param x The x offset to the given matrix.
    883
     * @param rows The number of rows of the new matrix.
    884
     * @param cols The number of cols of the new matrix.
    885
     */
    886
    ccv_dense_matrix_t ccv_reshape(ccv_dense_matrix_t* a, int y, int x, int rows, int cols);
    887
    888
    // 32-bit float to 16-bit float
    889
    void ccv_float_to_half_precision(const float* f, uint16_t* h, size_t len);
    890
    void ccv_half_precision_to_float(const uint16_t* h, float* f, size_t len);
    891
    892
    // 32-bit float to 16-bit bfloat
    893
    void ccv_float_to_bfloat(const float* f, uint16_t* h, size_t len);
    894
    void ccv_bfloat_to_float(const uint16_t* h, float* f, size_t len);
    895
    896
    // 64-bit float to 16-bit float
    897
    void ccv_double_to_half_precision(const double* f, uint16_t* h, size_t len);
    898
    void ccv_half_precision_to_double(const uint16_t* h, double* f, size_t len);
    899
    900
    // 64-bit float to 16-bit bfloat
    901
    void ccv_double_to_bfloat(const double* f, uint16_t* h, size_t len);
    902
    void ccv_bfloat_to_double(const uint16_t* h, double* f, size_t len);
    903
    904
    // 16-bit float to 16-bit bfloat
    905
    void ccv_bfloat_to_half_precision(const uint16_t* h, uint16_t* f, size_t len);
    906
    void ccv_half_precision_to_bfloat(const uint16_t* f, uint16_t* h, size_t len);
    907
    908
    /* basic data structures ccv_util.c */
    909
    910
    typedef struct {
    911
      int width;
    912
      int height;
    913
    } ccv_size_t;
    914
    915
    inline static ccv_size_t ccv_size(int width, int height)
    916
    29
    {
    917
    29
      ccv_size_t size;
    918
    29
      size.width = width;
    919
    29
      size.height = height;
    920
    29
      return size;
    921
    29
    }
    Unexecuted instantiation: adam.tests.c:ccv_size
    Unexecuted instantiation: cifar.tests.c:ccv_size
    Unexecuted instantiation: cnnp.core.tests.c:ccv_size
    Unexecuted instantiation: compare.tests.c:ccv_size
    Unexecuted instantiation: compression.tests.c:ccv_size
    Unexecuted instantiation: concat.tests.c:ccv_size
    Unexecuted instantiation: cublas.tests.c:ccv_size
    Unexecuted instantiation: cudnn.tests.c:ccv_size
    Unexecuted instantiation: datatype.tests.c:ccv_size
    Unexecuted instantiation: dense.net.tests.c:ccv_size
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_size
    Unexecuted instantiation: gelu.tests.c:ccv_size
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_size
    Unexecuted instantiation: imdb.tests.c:ccv_size
    Unexecuted instantiation: index.tests.c:ccv_size
    Unexecuted instantiation: lamb.tests.c:ccv_size
    Unexecuted instantiation: leaky_relu.tests.c:ccv_size
    Unexecuted instantiation: loss.tests.c:ccv_size
    Unexecuted instantiation: lstm.tests.c:ccv_size
    Unexecuted instantiation: mpsblas.tests.c:ccv_size
    Unexecuted instantiation: mpsdnn.tests.c:ccv_size
    Unexecuted instantiation: nccl.tests.c:ccv_size
    Unexecuted instantiation: nms.tests.c:ccv_size
    Unexecuted instantiation: pad.tests.c:ccv_size
    Unexecuted instantiation: palettize.tests.c:ccv_size
    Unexecuted instantiation: parallel.tests.c:ccv_size
    Unexecuted instantiation: partition.tests.c:ccv_size
    Unexecuted instantiation: random.tests.c:ccv_size
    Unexecuted instantiation: reduce.tests.c:ccv_size
    Unexecuted instantiation: rmsprop.tests.c:ccv_size
    Unexecuted instantiation: roi_align.tests.c:ccv_size
    Unexecuted instantiation: scatter_add.tests.c:ccv_size
    Unexecuted instantiation: schedule.tests.c:ccv_size
    Unexecuted instantiation: sgd.tests.c:ccv_size
    Unexecuted instantiation: smooth_l1.tests.c:ccv_size
    Unexecuted instantiation: sort.tests.c:ccv_size
    Unexecuted instantiation: swish.tests.c:ccv_size
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_size
    Unexecuted instantiation: tensor.tests.c:ccv_size
    Unexecuted instantiation: transform.tests.c:ccv_size
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_size
    Unexecuted instantiation: upsample.tests.c:ccv_size
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_size
    Unexecuted instantiation: 3rdparty.tests.c:ccv_size
    Unexecuted instantiation: algebra.tests.c:ccv_size
    Unexecuted instantiation: basic.tests.c:ccv_size

    convnet.tests.c:ccv_size

    Line
    Count
    Source
    916
    27
    {
    917
    27
      ccv_size_t size;
    918
    27
      size.width = width;
    919
    27
      size.height = height;
    920
    27
      return size;
    921
    27
    }
    Unexecuted instantiation: image_processing.tests.c:ccv_size
    Unexecuted instantiation: io.tests.c:ccv_size
    Unexecuted instantiation: memory.tests.c:ccv_size
    Unexecuted instantiation: attention.tests.c:ccv_size
    Unexecuted instantiation: autograd.tests.c:ccv_size
    Unexecuted instantiation: autograd.vector.tests.c:ccv_size
    Unexecuted instantiation: backward.tests.c:ccv_size
    Unexecuted instantiation: batch.norm.tests.c:ccv_size
    Unexecuted instantiation: broadcast.tests.c:ccv_size
    Unexecuted instantiation: case_of.backward.tests.c:ccv_size
    Unexecuted instantiation: case_of.tests.c:ccv_size
    Unexecuted instantiation: cblas.tests.c:ccv_size
    Unexecuted instantiation: complex.tests.c:ccv_size
    Unexecuted instantiation: crossentropy.tests.c:ccv_size
    Unexecuted instantiation: custom.tests.c:ccv_size
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_size
    Unexecuted instantiation: dataframe.tests.c:ccv_size
    Unexecuted instantiation: dropout.tests.c:ccv_size
    Unexecuted instantiation: forward.tests.c:ccv_size
    Unexecuted instantiation: gemm.tests.c:ccv_size
    Unexecuted instantiation: gradient.tests.c:ccv_size
    Unexecuted instantiation: graph.io.tests.c:ccv_size
    Unexecuted instantiation: graph.tests.c:ccv_size
    Unexecuted instantiation: group.norm.tests.c:ccv_size
    Unexecuted instantiation: histogram.tests.c:ccv_size
    Unexecuted instantiation: layer.norm.tests.c:ccv_size
    Unexecuted instantiation: micro.tests.c:ccv_size
    Unexecuted instantiation: minimize.tests.c:ccv_size
    Unexecuted instantiation: numa.tests.c:ccv_size
    Unexecuted instantiation: rand.tests.c:ccv_size
    Unexecuted instantiation: rmsnorm.tests.c:ccv_size
    Unexecuted instantiation: simplify.tests.c:ccv_size
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_size
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_size
    Unexecuted instantiation: tape.tests.c:ccv_size
    Unexecuted instantiation: tensor.bind.tests.c:ccv_size
    Unexecuted instantiation: tfb.tests.c:ccv_size
    Unexecuted instantiation: while.backward.tests.c:ccv_size
    Unexecuted instantiation: while.tests.c:ccv_size
    Unexecuted instantiation: winograd.tests.c:ccv_size
    Unexecuted instantiation: numeric.tests.c:ccv_size
    Unexecuted instantiation: output.tests.c:ccv_size
    Unexecuted instantiation: util.tests.c:ccv_size
    Unexecuted instantiation: ccv_cache.c:ccv_size
    Unexecuted instantiation: ccv_memory.c:ccv_size
    Unexecuted instantiation: ccv_io.c:ccv_size
    Unexecuted instantiation: ccv_numeric.c:ccv_size
    Unexecuted instantiation: ccv_algebra.c:ccv_size
    Unexecuted instantiation: ccv_util.c:ccv_size
    Unexecuted instantiation: ccv_basic.c:ccv_size
    Unexecuted instantiation: ccv_image_processing.c:ccv_size
    Unexecuted instantiation: ccv_resample.c:ccv_size
    Unexecuted instantiation: ccv_transform.c:ccv_size
    Unexecuted instantiation: ccv_classic.c:ccv_size

    ccv_convnet.c:ccv_size

    Line
    Count
    Source
    916
    2
    {
    917
    2
      ccv_size_t size;
    918
    2
      size.width = width;
    919
    2
      size.height = height;
    920
    2
      return size;
    921
    2
    }
    Unexecuted instantiation: ccv_output.c:ccv_size
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_size
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_size
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_size
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_size
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_size
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_size
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_size
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_size
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_size
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_size
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_size
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_size
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_size
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_size
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_size
    Unexecuted instantiation: co.c:ccv_size
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_size
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_size
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_size
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_size
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_size
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_size
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_size
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_size
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_size
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_size
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_size
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_size
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_size
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_size
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_size
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_size
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_size
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_size
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_size
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_size
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_size
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_size
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_size
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_size
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_size
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_size
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_size
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_size
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_size
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_size
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_size
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_size
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_size
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_size
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_size
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_size
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_size
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_size
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_size
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_size
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_size
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_size
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_size
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_size
    Unexecuted instantiation: ccv_nnc_util.c:ccv_size
    922
    923
    inline static int ccv_size_is_zero(ccv_size_t size)
    924
    0
    {
    925
    0
      return size.width == 0 && size.height == 0;
    926
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_size_is_zero
    Unexecuted instantiation: cifar.tests.c:ccv_size_is_zero
    Unexecuted instantiation: cnnp.core.tests.c:ccv_size_is_zero
    Unexecuted instantiation: compare.tests.c:ccv_size_is_zero
    Unexecuted instantiation: compression.tests.c:ccv_size_is_zero
    Unexecuted instantiation: concat.tests.c:ccv_size_is_zero
    Unexecuted instantiation: cublas.tests.c:ccv_size_is_zero
    Unexecuted instantiation: cudnn.tests.c:ccv_size_is_zero
    Unexecuted instantiation: datatype.tests.c:ccv_size_is_zero
    Unexecuted instantiation: dense.net.tests.c:ccv_size_is_zero
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_size_is_zero
    Unexecuted instantiation: gelu.tests.c:ccv_size_is_zero
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_size_is_zero
    Unexecuted instantiation: imdb.tests.c:ccv_size_is_zero
    Unexecuted instantiation: index.tests.c:ccv_size_is_zero
    Unexecuted instantiation: lamb.tests.c:ccv_size_is_zero
    Unexecuted instantiation: leaky_relu.tests.c:ccv_size_is_zero
    Unexecuted instantiation: loss.tests.c:ccv_size_is_zero
    Unexecuted instantiation: lstm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: mpsblas.tests.c:ccv_size_is_zero
    Unexecuted instantiation: mpsdnn.tests.c:ccv_size_is_zero
    Unexecuted instantiation: nccl.tests.c:ccv_size_is_zero
    Unexecuted instantiation: nms.tests.c:ccv_size_is_zero
    Unexecuted instantiation: pad.tests.c:ccv_size_is_zero
    Unexecuted instantiation: palettize.tests.c:ccv_size_is_zero
    Unexecuted instantiation: parallel.tests.c:ccv_size_is_zero
    Unexecuted instantiation: partition.tests.c:ccv_size_is_zero
    Unexecuted instantiation: random.tests.c:ccv_size_is_zero
    Unexecuted instantiation: reduce.tests.c:ccv_size_is_zero
    Unexecuted instantiation: rmsprop.tests.c:ccv_size_is_zero
    Unexecuted instantiation: roi_align.tests.c:ccv_size_is_zero
    Unexecuted instantiation: scatter_add.tests.c:ccv_size_is_zero
    Unexecuted instantiation: schedule.tests.c:ccv_size_is_zero
    Unexecuted instantiation: sgd.tests.c:ccv_size_is_zero
    Unexecuted instantiation: smooth_l1.tests.c:ccv_size_is_zero
    Unexecuted instantiation: sort.tests.c:ccv_size_is_zero
    Unexecuted instantiation: swish.tests.c:ccv_size_is_zero
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_size_is_zero
    Unexecuted instantiation: tensor.tests.c:ccv_size_is_zero
    Unexecuted instantiation: transform.tests.c:ccv_size_is_zero
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_size_is_zero
    Unexecuted instantiation: upsample.tests.c:ccv_size_is_zero
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_size_is_zero
    Unexecuted instantiation: 3rdparty.tests.c:ccv_size_is_zero
    Unexecuted instantiation: algebra.tests.c:ccv_size_is_zero
    Unexecuted instantiation: basic.tests.c:ccv_size_is_zero
    Unexecuted instantiation: convnet.tests.c:ccv_size_is_zero
    Unexecuted instantiation: image_processing.tests.c:ccv_size_is_zero
    Unexecuted instantiation: io.tests.c:ccv_size_is_zero
    Unexecuted instantiation: memory.tests.c:ccv_size_is_zero
    Unexecuted instantiation: attention.tests.c:ccv_size_is_zero
    Unexecuted instantiation: autograd.tests.c:ccv_size_is_zero
    Unexecuted instantiation: autograd.vector.tests.c:ccv_size_is_zero
    Unexecuted instantiation: backward.tests.c:ccv_size_is_zero
    Unexecuted instantiation: batch.norm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: broadcast.tests.c:ccv_size_is_zero
    Unexecuted instantiation: case_of.backward.tests.c:ccv_size_is_zero
    Unexecuted instantiation: case_of.tests.c:ccv_size_is_zero
    Unexecuted instantiation: cblas.tests.c:ccv_size_is_zero
    Unexecuted instantiation: complex.tests.c:ccv_size_is_zero
    Unexecuted instantiation: crossentropy.tests.c:ccv_size_is_zero
    Unexecuted instantiation: custom.tests.c:ccv_size_is_zero
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_size_is_zero
    Unexecuted instantiation: dataframe.tests.c:ccv_size_is_zero
    Unexecuted instantiation: dropout.tests.c:ccv_size_is_zero
    Unexecuted instantiation: forward.tests.c:ccv_size_is_zero
    Unexecuted instantiation: gemm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: gradient.tests.c:ccv_size_is_zero
    Unexecuted instantiation: graph.io.tests.c:ccv_size_is_zero
    Unexecuted instantiation: graph.tests.c:ccv_size_is_zero
    Unexecuted instantiation: group.norm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: histogram.tests.c:ccv_size_is_zero
    Unexecuted instantiation: layer.norm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: micro.tests.c:ccv_size_is_zero
    Unexecuted instantiation: minimize.tests.c:ccv_size_is_zero
    Unexecuted instantiation: numa.tests.c:ccv_size_is_zero
    Unexecuted instantiation: rand.tests.c:ccv_size_is_zero
    Unexecuted instantiation: rmsnorm.tests.c:ccv_size_is_zero
    Unexecuted instantiation: simplify.tests.c:ccv_size_is_zero
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_size_is_zero
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_size_is_zero
    Unexecuted instantiation: tape.tests.c:ccv_size_is_zero
    Unexecuted instantiation: tensor.bind.tests.c:ccv_size_is_zero
    Unexecuted instantiation: tfb.tests.c:ccv_size_is_zero
    Unexecuted instantiation: while.backward.tests.c:ccv_size_is_zero
    Unexecuted instantiation: while.tests.c:ccv_size_is_zero
    Unexecuted instantiation: winograd.tests.c:ccv_size_is_zero
    Unexecuted instantiation: numeric.tests.c:ccv_size_is_zero
    Unexecuted instantiation: output.tests.c:ccv_size_is_zero
    Unexecuted instantiation: util.tests.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cache.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_memory.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_io.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_numeric.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_algebra.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_util.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_basic.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_image_processing.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_resample.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_transform.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_classic.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_convnet.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_output.c:ccv_size_is_zero
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_size_is_zero
    Unexecuted instantiation: co.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_size_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_size_is_zero
    Unexecuted instantiation: ccv_nnc_util.c:ccv_size_is_zero
    927
    928
    typedef struct {
    929
      int x;
    930
      int y;
    931
      int width;
    932
      int height;
    933
    } ccv_rect_t;
    934
    935
    inline static ccv_rect_t ccv_rect(int x, int y, int width, int height)
    936
    0
    {
    937
    0
      ccv_rect_t rect;
    938
    0
      rect.x = x;
    939
    0
      rect.y = y;
    940
    0
      rect.width = width;
    941
    0
      rect.height = height;
    942
    0
      return rect;
    943
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_rect
    Unexecuted instantiation: cifar.tests.c:ccv_rect
    Unexecuted instantiation: cnnp.core.tests.c:ccv_rect
    Unexecuted instantiation: compare.tests.c:ccv_rect
    Unexecuted instantiation: compression.tests.c:ccv_rect
    Unexecuted instantiation: concat.tests.c:ccv_rect
    Unexecuted instantiation: cublas.tests.c:ccv_rect
    Unexecuted instantiation: cudnn.tests.c:ccv_rect
    Unexecuted instantiation: datatype.tests.c:ccv_rect
    Unexecuted instantiation: dense.net.tests.c:ccv_rect
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_rect
    Unexecuted instantiation: gelu.tests.c:ccv_rect
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_rect
    Unexecuted instantiation: imdb.tests.c:ccv_rect
    Unexecuted instantiation: index.tests.c:ccv_rect
    Unexecuted instantiation: lamb.tests.c:ccv_rect
    Unexecuted instantiation: leaky_relu.tests.c:ccv_rect
    Unexecuted instantiation: loss.tests.c:ccv_rect
    Unexecuted instantiation: lstm.tests.c:ccv_rect
    Unexecuted instantiation: mpsblas.tests.c:ccv_rect
    Unexecuted instantiation: mpsdnn.tests.c:ccv_rect
    Unexecuted instantiation: nccl.tests.c:ccv_rect
    Unexecuted instantiation: nms.tests.c:ccv_rect
    Unexecuted instantiation: pad.tests.c:ccv_rect
    Unexecuted instantiation: palettize.tests.c:ccv_rect
    Unexecuted instantiation: parallel.tests.c:ccv_rect
    Unexecuted instantiation: partition.tests.c:ccv_rect
    Unexecuted instantiation: random.tests.c:ccv_rect
    Unexecuted instantiation: reduce.tests.c:ccv_rect
    Unexecuted instantiation: rmsprop.tests.c:ccv_rect
    Unexecuted instantiation: roi_align.tests.c:ccv_rect
    Unexecuted instantiation: scatter_add.tests.c:ccv_rect
    Unexecuted instantiation: schedule.tests.c:ccv_rect
    Unexecuted instantiation: sgd.tests.c:ccv_rect
    Unexecuted instantiation: smooth_l1.tests.c:ccv_rect
    Unexecuted instantiation: sort.tests.c:ccv_rect
    Unexecuted instantiation: swish.tests.c:ccv_rect
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_rect
    Unexecuted instantiation: tensor.tests.c:ccv_rect
    Unexecuted instantiation: transform.tests.c:ccv_rect
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_rect
    Unexecuted instantiation: upsample.tests.c:ccv_rect
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_rect
    Unexecuted instantiation: 3rdparty.tests.c:ccv_rect
    Unexecuted instantiation: algebra.tests.c:ccv_rect
    Unexecuted instantiation: basic.tests.c:ccv_rect
    Unexecuted instantiation: convnet.tests.c:ccv_rect
    Unexecuted instantiation: image_processing.tests.c:ccv_rect
    Unexecuted instantiation: io.tests.c:ccv_rect
    Unexecuted instantiation: memory.tests.c:ccv_rect
    Unexecuted instantiation: attention.tests.c:ccv_rect
    Unexecuted instantiation: autograd.tests.c:ccv_rect
    Unexecuted instantiation: autograd.vector.tests.c:ccv_rect
    Unexecuted instantiation: backward.tests.c:ccv_rect
    Unexecuted instantiation: batch.norm.tests.c:ccv_rect
    Unexecuted instantiation: broadcast.tests.c:ccv_rect
    Unexecuted instantiation: case_of.backward.tests.c:ccv_rect
    Unexecuted instantiation: case_of.tests.c:ccv_rect
    Unexecuted instantiation: cblas.tests.c:ccv_rect
    Unexecuted instantiation: complex.tests.c:ccv_rect
    Unexecuted instantiation: crossentropy.tests.c:ccv_rect
    Unexecuted instantiation: custom.tests.c:ccv_rect
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_rect
    Unexecuted instantiation: dataframe.tests.c:ccv_rect
    Unexecuted instantiation: dropout.tests.c:ccv_rect
    Unexecuted instantiation: forward.tests.c:ccv_rect
    Unexecuted instantiation: gemm.tests.c:ccv_rect
    Unexecuted instantiation: gradient.tests.c:ccv_rect
    Unexecuted instantiation: graph.io.tests.c:ccv_rect
    Unexecuted instantiation: graph.tests.c:ccv_rect
    Unexecuted instantiation: group.norm.tests.c:ccv_rect
    Unexecuted instantiation: histogram.tests.c:ccv_rect
    Unexecuted instantiation: layer.norm.tests.c:ccv_rect
    Unexecuted instantiation: micro.tests.c:ccv_rect
    Unexecuted instantiation: minimize.tests.c:ccv_rect
    Unexecuted instantiation: numa.tests.c:ccv_rect
    Unexecuted instantiation: rand.tests.c:ccv_rect
    Unexecuted instantiation: rmsnorm.tests.c:ccv_rect
    Unexecuted instantiation: simplify.tests.c:ccv_rect
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_rect
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_rect
    Unexecuted instantiation: tape.tests.c:ccv_rect
    Unexecuted instantiation: tensor.bind.tests.c:ccv_rect
    Unexecuted instantiation: tfb.tests.c:ccv_rect
    Unexecuted instantiation: while.backward.tests.c:ccv_rect
    Unexecuted instantiation: while.tests.c:ccv_rect
    Unexecuted instantiation: winograd.tests.c:ccv_rect
    Unexecuted instantiation: numeric.tests.c:ccv_rect
    Unexecuted instantiation: output.tests.c:ccv_rect
    Unexecuted instantiation: util.tests.c:ccv_rect
    Unexecuted instantiation: ccv_cache.c:ccv_rect
    Unexecuted instantiation: ccv_memory.c:ccv_rect
    Unexecuted instantiation: ccv_io.c:ccv_rect
    Unexecuted instantiation: ccv_numeric.c:ccv_rect
    Unexecuted instantiation: ccv_algebra.c:ccv_rect
    Unexecuted instantiation: ccv_util.c:ccv_rect
    Unexecuted instantiation: ccv_basic.c:ccv_rect
    Unexecuted instantiation: ccv_image_processing.c:ccv_rect
    Unexecuted instantiation: ccv_resample.c:ccv_rect
    Unexecuted instantiation: ccv_transform.c:ccv_rect
    Unexecuted instantiation: ccv_classic.c:ccv_rect
    Unexecuted instantiation: ccv_convnet.c:ccv_rect
    Unexecuted instantiation: ccv_output.c:ccv_rect
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_rect
    Unexecuted instantiation: co.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_rect
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_rect
    Unexecuted instantiation: ccv_nnc_util.c:ccv_rect
    944
    945
    inline static int ccv_rect_is_zero(ccv_rect_t rect)
    946
    0
    {
    947
    0
      return rect.x == 0 && rect.y == 0 && rect.width == 0 && rect.height == 0;
    948
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: cifar.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: cnnp.core.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: compare.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: compression.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: concat.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: cublas.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: cudnn.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: datatype.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: dense.net.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: gelu.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: imdb.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: index.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: lamb.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: leaky_relu.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: loss.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: lstm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: mpsblas.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: mpsdnn.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: nccl.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: nms.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: pad.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: palettize.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: parallel.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: partition.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: random.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: reduce.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: rmsprop.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: roi_align.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: scatter_add.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: schedule.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: sgd.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: smooth_l1.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: sort.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: swish.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: tensor.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: transform.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: upsample.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: 3rdparty.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: algebra.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: basic.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: convnet.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: image_processing.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: io.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: memory.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: attention.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: autograd.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: autograd.vector.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: backward.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: batch.norm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: broadcast.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: case_of.backward.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: case_of.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: cblas.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: complex.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: crossentropy.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: custom.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: dataframe.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: dropout.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: forward.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: gemm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: gradient.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: graph.io.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: graph.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: group.norm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: histogram.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: layer.norm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: micro.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: minimize.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: numa.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: rand.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: rmsnorm.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: simplify.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: tape.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: tensor.bind.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: tfb.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: while.backward.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: while.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: winograd.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: numeric.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: output.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: util.tests.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cache.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_memory.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_io.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_numeric.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_algebra.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_util.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_basic.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_image_processing.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_resample.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_transform.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_classic.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_convnet.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_output.c:ccv_rect_is_zero
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_rect_is_zero
    Unexecuted instantiation: co.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_rect_is_zero
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_rect_is_zero
    Unexecuted instantiation: ccv_nnc_util.c:ccv_rect_is_zero
    949
    950
    typedef struct {
    951
      float x;
    952
      float y;
    953
      float width;
    954
      float height;
    955
    } ccv_decimal_rect_t;
    956
    957
    inline static ccv_decimal_rect_t ccv_decimal_rect(float x, float y, float width, float height)
    958
    0
    {
    959
    0
      ccv_decimal_rect_t rect;
    960
    0
      rect.x = x;
    961
    0
      rect.y = y;
    962
    0
      rect.width = width;
    963
    0
      rect.height = height;
    964
    0
      return rect;
    965
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_decimal_rect
    Unexecuted instantiation: cifar.tests.c:ccv_decimal_rect
    Unexecuted instantiation: cnnp.core.tests.c:ccv_decimal_rect
    Unexecuted instantiation: compare.tests.c:ccv_decimal_rect
    Unexecuted instantiation: compression.tests.c:ccv_decimal_rect
    Unexecuted instantiation: concat.tests.c:ccv_decimal_rect
    Unexecuted instantiation: cublas.tests.c:ccv_decimal_rect
    Unexecuted instantiation: cudnn.tests.c:ccv_decimal_rect
    Unexecuted instantiation: datatype.tests.c:ccv_decimal_rect
    Unexecuted instantiation: dense.net.tests.c:ccv_decimal_rect
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_decimal_rect
    Unexecuted instantiation: gelu.tests.c:ccv_decimal_rect
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_decimal_rect
    Unexecuted instantiation: imdb.tests.c:ccv_decimal_rect
    Unexecuted instantiation: index.tests.c:ccv_decimal_rect
    Unexecuted instantiation: lamb.tests.c:ccv_decimal_rect
    Unexecuted instantiation: leaky_relu.tests.c:ccv_decimal_rect
    Unexecuted instantiation: loss.tests.c:ccv_decimal_rect
    Unexecuted instantiation: lstm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: mpsblas.tests.c:ccv_decimal_rect
    Unexecuted instantiation: mpsdnn.tests.c:ccv_decimal_rect
    Unexecuted instantiation: nccl.tests.c:ccv_decimal_rect
    Unexecuted instantiation: nms.tests.c:ccv_decimal_rect
    Unexecuted instantiation: pad.tests.c:ccv_decimal_rect
    Unexecuted instantiation: palettize.tests.c:ccv_decimal_rect
    Unexecuted instantiation: parallel.tests.c:ccv_decimal_rect
    Unexecuted instantiation: partition.tests.c:ccv_decimal_rect
    Unexecuted instantiation: random.tests.c:ccv_decimal_rect
    Unexecuted instantiation: reduce.tests.c:ccv_decimal_rect
    Unexecuted instantiation: rmsprop.tests.c:ccv_decimal_rect
    Unexecuted instantiation: roi_align.tests.c:ccv_decimal_rect
    Unexecuted instantiation: scatter_add.tests.c:ccv_decimal_rect
    Unexecuted instantiation: schedule.tests.c:ccv_decimal_rect
    Unexecuted instantiation: sgd.tests.c:ccv_decimal_rect
    Unexecuted instantiation: smooth_l1.tests.c:ccv_decimal_rect
    Unexecuted instantiation: sort.tests.c:ccv_decimal_rect
    Unexecuted instantiation: swish.tests.c:ccv_decimal_rect
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_decimal_rect
    Unexecuted instantiation: tensor.tests.c:ccv_decimal_rect
    Unexecuted instantiation: transform.tests.c:ccv_decimal_rect
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_decimal_rect
    Unexecuted instantiation: upsample.tests.c:ccv_decimal_rect
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_decimal_rect
    Unexecuted instantiation: 3rdparty.tests.c:ccv_decimal_rect
    Unexecuted instantiation: algebra.tests.c:ccv_decimal_rect
    Unexecuted instantiation: basic.tests.c:ccv_decimal_rect
    Unexecuted instantiation: convnet.tests.c:ccv_decimal_rect
    Unexecuted instantiation: image_processing.tests.c:ccv_decimal_rect
    Unexecuted instantiation: io.tests.c:ccv_decimal_rect
    Unexecuted instantiation: memory.tests.c:ccv_decimal_rect
    Unexecuted instantiation: attention.tests.c:ccv_decimal_rect
    Unexecuted instantiation: autograd.tests.c:ccv_decimal_rect
    Unexecuted instantiation: autograd.vector.tests.c:ccv_decimal_rect
    Unexecuted instantiation: backward.tests.c:ccv_decimal_rect
    Unexecuted instantiation: batch.norm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: broadcast.tests.c:ccv_decimal_rect
    Unexecuted instantiation: case_of.backward.tests.c:ccv_decimal_rect
    Unexecuted instantiation: case_of.tests.c:ccv_decimal_rect
    Unexecuted instantiation: cblas.tests.c:ccv_decimal_rect
    Unexecuted instantiation: complex.tests.c:ccv_decimal_rect
    Unexecuted instantiation: crossentropy.tests.c:ccv_decimal_rect
    Unexecuted instantiation: custom.tests.c:ccv_decimal_rect
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_decimal_rect
    Unexecuted instantiation: dataframe.tests.c:ccv_decimal_rect
    Unexecuted instantiation: dropout.tests.c:ccv_decimal_rect
    Unexecuted instantiation: forward.tests.c:ccv_decimal_rect
    Unexecuted instantiation: gemm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: gradient.tests.c:ccv_decimal_rect
    Unexecuted instantiation: graph.io.tests.c:ccv_decimal_rect
    Unexecuted instantiation: graph.tests.c:ccv_decimal_rect
    Unexecuted instantiation: group.norm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: histogram.tests.c:ccv_decimal_rect
    Unexecuted instantiation: layer.norm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: micro.tests.c:ccv_decimal_rect
    Unexecuted instantiation: minimize.tests.c:ccv_decimal_rect
    Unexecuted instantiation: numa.tests.c:ccv_decimal_rect
    Unexecuted instantiation: rand.tests.c:ccv_decimal_rect
    Unexecuted instantiation: rmsnorm.tests.c:ccv_decimal_rect
    Unexecuted instantiation: simplify.tests.c:ccv_decimal_rect
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_decimal_rect
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_decimal_rect
    Unexecuted instantiation: tape.tests.c:ccv_decimal_rect
    Unexecuted instantiation: tensor.bind.tests.c:ccv_decimal_rect
    Unexecuted instantiation: tfb.tests.c:ccv_decimal_rect
    Unexecuted instantiation: while.backward.tests.c:ccv_decimal_rect
    Unexecuted instantiation: while.tests.c:ccv_decimal_rect
    Unexecuted instantiation: winograd.tests.c:ccv_decimal_rect
    Unexecuted instantiation: numeric.tests.c:ccv_decimal_rect
    Unexecuted instantiation: output.tests.c:ccv_decimal_rect
    Unexecuted instantiation: util.tests.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cache.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_memory.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_io.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_numeric.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_algebra.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_util.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_basic.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_image_processing.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_resample.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_transform.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_classic.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_convnet.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_output.c:ccv_decimal_rect
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_decimal_rect
    Unexecuted instantiation: co.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_decimal_rect
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_decimal_rect
    Unexecuted instantiation: ccv_nnc_util.c:ccv_decimal_rect
    966
    967
    typedef struct {
    968
      int type;
    969
      uint64_t sig;
    970
      int refcount;
    971
      int rnum;
    972
      int size;
    973
      int rsize;
    974
      void* data;
    975
    } ccv_array_t;
    976
    977
    /**
    978
     * Create a new, self-growing array.
    979
     * @param rnum The initial capacity of the array.
    980
     * @param rsize The size of each element in the array.
    981
     * @param sig The signature for this array.
    982
     */
    983
    CCV_WARN_UNUSED(ccv_array_t*) ccv_array_new(int rsize, int rnum, uint64_t sig);
    984
    /**
    985
     * Push a new element into the array.
    986
     * @param array The array.
    987
     * @param r The pointer to new element, it will then be copied into the array.
    988
     */
    989
    void ccv_array_push(ccv_array_t* array, const void* r);
    990
    typedef int(*ccv_array_group_f)(const void*, const void*, void*);
    991
    /**
    992
     * Group elements in the array from its similarity.
    993
     * @param array The array.
    994
     * @param index The output index, same group element will have the same index.
    995
     * @param gfunc int ccv_array_group_f(const void* a, const void* b, void* data). Return 1 if a and b are in the same group.
    996
     * @param data Any extra user data.
    997
     */
    998
    int ccv_array_group(ccv_array_t* array, ccv_array_t** index, ccv_array_group_f gfunc, void* data);
    999
    void ccv_make_array_immutable(ccv_array_t* array);
    1000
    void ccv_make_array_mutable(ccv_array_t* array);
    1001
    /**
    1002
     * Zero out the array, it won't change the array->rnum however.
    1003
     * @param array The array.
    1004
     */
    1005
    void ccv_array_zero(ccv_array_t* array);
    1006
    /**
    1007
     * Resize the array, it will change the array->rnum and zero init the rest.
    1008
     * @param array The array.
    1009
     * @param rnum The expanded size of the array.
    1010
     */
    1011
    void ccv_array_resize(ccv_array_t* array, int rnum);
    1012
    /**
    1013
     * Clear the array, it will reset the array->rnum to 0.
    1014
     * @param array The array.
    1015
     */
    1016
    void ccv_array_clear(ccv_array_t* array);
    1017
    /**
    1018
     * Free up the array immediately.
    1019
     * @param array The array.
    1020
     */
    1021
    void ccv_array_free_immediately(ccv_array_t* array);
    1022
    /**
    1023
     * Free up the array. If array's signature is non-zero, we may put it into cache so that later on, we can shortcut and return this array directly.
    1024
     * @param array The array.
    1025
     */
    1026
    void ccv_array_free(ccv_array_t* array);
    1027
    /**
    1028
     * Get a specific element from an array
    1029
     * @param a The array.
    1030
     * @param i The index of the element in the array.
    1031
     */
    1032
    22.6M
    #define ccv_array_get(a, i) ((void*)(((char*)((a)->data)) + (size_t)(a)->rsize * (size_t)(i65.9k)))
    1033
    1034
    typedef struct {
    1035
      int x, y;
    1036
    } ccv_point_t;
    1037
    1038
    inline static ccv_point_t ccv_point(int x, int y)
    1039
    0
    {
    1040
    0
      ccv_point_t point;
    1041
    0
      point.x = x;
    1042
    0
      point.y = y;
    1043
    0
      return point;
    1044
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_point
    Unexecuted instantiation: cifar.tests.c:ccv_point
    Unexecuted instantiation: cnnp.core.tests.c:ccv_point
    Unexecuted instantiation: compare.tests.c:ccv_point
    Unexecuted instantiation: compression.tests.c:ccv_point
    Unexecuted instantiation: concat.tests.c:ccv_point
    Unexecuted instantiation: cublas.tests.c:ccv_point
    Unexecuted instantiation: cudnn.tests.c:ccv_point
    Unexecuted instantiation: datatype.tests.c:ccv_point
    Unexecuted instantiation: dense.net.tests.c:ccv_point
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_point
    Unexecuted instantiation: gelu.tests.c:ccv_point
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_point
    Unexecuted instantiation: imdb.tests.c:ccv_point
    Unexecuted instantiation: index.tests.c:ccv_point
    Unexecuted instantiation: lamb.tests.c:ccv_point
    Unexecuted instantiation: leaky_relu.tests.c:ccv_point
    Unexecuted instantiation: loss.tests.c:ccv_point
    Unexecuted instantiation: lstm.tests.c:ccv_point
    Unexecuted instantiation: mpsblas.tests.c:ccv_point
    Unexecuted instantiation: mpsdnn.tests.c:ccv_point
    Unexecuted instantiation: nccl.tests.c:ccv_point
    Unexecuted instantiation: nms.tests.c:ccv_point
    Unexecuted instantiation: pad.tests.c:ccv_point
    Unexecuted instantiation: palettize.tests.c:ccv_point
    Unexecuted instantiation: parallel.tests.c:ccv_point
    Unexecuted instantiation: partition.tests.c:ccv_point
    Unexecuted instantiation: random.tests.c:ccv_point
    Unexecuted instantiation: reduce.tests.c:ccv_point
    Unexecuted instantiation: rmsprop.tests.c:ccv_point
    Unexecuted instantiation: roi_align.tests.c:ccv_point
    Unexecuted instantiation: scatter_add.tests.c:ccv_point
    Unexecuted instantiation: schedule.tests.c:ccv_point
    Unexecuted instantiation: sgd.tests.c:ccv_point
    Unexecuted instantiation: smooth_l1.tests.c:ccv_point
    Unexecuted instantiation: sort.tests.c:ccv_point
    Unexecuted instantiation: swish.tests.c:ccv_point
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_point
    Unexecuted instantiation: tensor.tests.c:ccv_point
    Unexecuted instantiation: transform.tests.c:ccv_point
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_point
    Unexecuted instantiation: upsample.tests.c:ccv_point
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_point
    Unexecuted instantiation: 3rdparty.tests.c:ccv_point
    Unexecuted instantiation: algebra.tests.c:ccv_point
    Unexecuted instantiation: basic.tests.c:ccv_point
    Unexecuted instantiation: convnet.tests.c:ccv_point
    Unexecuted instantiation: image_processing.tests.c:ccv_point
    Unexecuted instantiation: io.tests.c:ccv_point
    Unexecuted instantiation: memory.tests.c:ccv_point
    Unexecuted instantiation: attention.tests.c:ccv_point
    Unexecuted instantiation: autograd.tests.c:ccv_point
    Unexecuted instantiation: autograd.vector.tests.c:ccv_point
    Unexecuted instantiation: backward.tests.c:ccv_point
    Unexecuted instantiation: batch.norm.tests.c:ccv_point
    Unexecuted instantiation: broadcast.tests.c:ccv_point
    Unexecuted instantiation: case_of.backward.tests.c:ccv_point
    Unexecuted instantiation: case_of.tests.c:ccv_point
    Unexecuted instantiation: cblas.tests.c:ccv_point
    Unexecuted instantiation: complex.tests.c:ccv_point
    Unexecuted instantiation: crossentropy.tests.c:ccv_point
    Unexecuted instantiation: custom.tests.c:ccv_point
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_point
    Unexecuted instantiation: dataframe.tests.c:ccv_point
    Unexecuted instantiation: dropout.tests.c:ccv_point
    Unexecuted instantiation: forward.tests.c:ccv_point
    Unexecuted instantiation: gemm.tests.c:ccv_point
    Unexecuted instantiation: gradient.tests.c:ccv_point
    Unexecuted instantiation: graph.io.tests.c:ccv_point
    Unexecuted instantiation: graph.tests.c:ccv_point
    Unexecuted instantiation: group.norm.tests.c:ccv_point
    Unexecuted instantiation: histogram.tests.c:ccv_point
    Unexecuted instantiation: layer.norm.tests.c:ccv_point
    Unexecuted instantiation: micro.tests.c:ccv_point
    Unexecuted instantiation: minimize.tests.c:ccv_point
    Unexecuted instantiation: numa.tests.c:ccv_point
    Unexecuted instantiation: rand.tests.c:ccv_point
    Unexecuted instantiation: rmsnorm.tests.c:ccv_point
    Unexecuted instantiation: simplify.tests.c:ccv_point
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_point
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_point
    Unexecuted instantiation: tape.tests.c:ccv_point
    Unexecuted instantiation: tensor.bind.tests.c:ccv_point
    Unexecuted instantiation: tfb.tests.c:ccv_point
    Unexecuted instantiation: while.backward.tests.c:ccv_point
    Unexecuted instantiation: while.tests.c:ccv_point
    Unexecuted instantiation: winograd.tests.c:ccv_point
    Unexecuted instantiation: numeric.tests.c:ccv_point
    Unexecuted instantiation: output.tests.c:ccv_point
    Unexecuted instantiation: util.tests.c:ccv_point
    Unexecuted instantiation: ccv_cache.c:ccv_point
    Unexecuted instantiation: ccv_memory.c:ccv_point
    Unexecuted instantiation: ccv_io.c:ccv_point
    Unexecuted instantiation: ccv_numeric.c:ccv_point
    Unexecuted instantiation: ccv_algebra.c:ccv_point
    Unexecuted instantiation: ccv_util.c:ccv_point
    Unexecuted instantiation: ccv_basic.c:ccv_point
    Unexecuted instantiation: ccv_image_processing.c:ccv_point
    Unexecuted instantiation: ccv_resample.c:ccv_point
    Unexecuted instantiation: ccv_transform.c:ccv_point
    Unexecuted instantiation: ccv_classic.c:ccv_point
    Unexecuted instantiation: ccv_convnet.c:ccv_point
    Unexecuted instantiation: ccv_output.c:ccv_point
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_point
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_point
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_point
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_point
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_point
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_point
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_point
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_point
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_point
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_point
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_point
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_point
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_point
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_point
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_point
    Unexecuted instantiation: co.c:ccv_point
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_point
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_point
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_point
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_point
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_point
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_point
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_point
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_point
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_point
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_point
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_point
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_point
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_point
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_point
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_point
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_point
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_point
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_point
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_point
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_point
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_point
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_point
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_point
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_point
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_point
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_point
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_point
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_point
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_point
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_point
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_point
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_point
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_point
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_point
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_point
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_point
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_point
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_point
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_point
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_point
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_point
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_point
    Unexecuted instantiation: ccv_nnc_util.c:ccv_point
    1045
    1046
    typedef struct {
    1047
      float x, y;
    1048
    } ccv_decimal_point_t;
    1049
    1050
    inline static ccv_decimal_point_t ccv_decimal_point(float x, float y)
    1051
    0
    {
    1052
    0
      ccv_decimal_point_t point;
    1053
    0
      point.x = x;
    1054
    0
      point.y = y;
    1055
    0
      return point;
    1056
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_decimal_point
    Unexecuted instantiation: cifar.tests.c:ccv_decimal_point
    Unexecuted instantiation: cnnp.core.tests.c:ccv_decimal_point
    Unexecuted instantiation: compare.tests.c:ccv_decimal_point
    Unexecuted instantiation: compression.tests.c:ccv_decimal_point
    Unexecuted instantiation: concat.tests.c:ccv_decimal_point
    Unexecuted instantiation: cublas.tests.c:ccv_decimal_point
    Unexecuted instantiation: cudnn.tests.c:ccv_decimal_point
    Unexecuted instantiation: datatype.tests.c:ccv_decimal_point
    Unexecuted instantiation: dense.net.tests.c:ccv_decimal_point
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_decimal_point
    Unexecuted instantiation: gelu.tests.c:ccv_decimal_point
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_decimal_point
    Unexecuted instantiation: imdb.tests.c:ccv_decimal_point
    Unexecuted instantiation: index.tests.c:ccv_decimal_point
    Unexecuted instantiation: lamb.tests.c:ccv_decimal_point
    Unexecuted instantiation: leaky_relu.tests.c:ccv_decimal_point
    Unexecuted instantiation: loss.tests.c:ccv_decimal_point
    Unexecuted instantiation: lstm.tests.c:ccv_decimal_point
    Unexecuted instantiation: mpsblas.tests.c:ccv_decimal_point
    Unexecuted instantiation: mpsdnn.tests.c:ccv_decimal_point
    Unexecuted instantiation: nccl.tests.c:ccv_decimal_point
    Unexecuted instantiation: nms.tests.c:ccv_decimal_point
    Unexecuted instantiation: pad.tests.c:ccv_decimal_point
    Unexecuted instantiation: palettize.tests.c:ccv_decimal_point
    Unexecuted instantiation: parallel.tests.c:ccv_decimal_point
    Unexecuted instantiation: partition.tests.c:ccv_decimal_point
    Unexecuted instantiation: random.tests.c:ccv_decimal_point
    Unexecuted instantiation: reduce.tests.c:ccv_decimal_point
    Unexecuted instantiation: rmsprop.tests.c:ccv_decimal_point
    Unexecuted instantiation: roi_align.tests.c:ccv_decimal_point
    Unexecuted instantiation: scatter_add.tests.c:ccv_decimal_point
    Unexecuted instantiation: schedule.tests.c:ccv_decimal_point
    Unexecuted instantiation: sgd.tests.c:ccv_decimal_point
    Unexecuted instantiation: smooth_l1.tests.c:ccv_decimal_point
    Unexecuted instantiation: sort.tests.c:ccv_decimal_point
    Unexecuted instantiation: swish.tests.c:ccv_decimal_point
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_decimal_point
    Unexecuted instantiation: tensor.tests.c:ccv_decimal_point
    Unexecuted instantiation: transform.tests.c:ccv_decimal_point
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_decimal_point
    Unexecuted instantiation: upsample.tests.c:ccv_decimal_point
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_decimal_point
    Unexecuted instantiation: 3rdparty.tests.c:ccv_decimal_point
    Unexecuted instantiation: algebra.tests.c:ccv_decimal_point
    Unexecuted instantiation: basic.tests.c:ccv_decimal_point
    Unexecuted instantiation: convnet.tests.c:ccv_decimal_point
    Unexecuted instantiation: image_processing.tests.c:ccv_decimal_point
    Unexecuted instantiation: io.tests.c:ccv_decimal_point
    Unexecuted instantiation: memory.tests.c:ccv_decimal_point
    Unexecuted instantiation: attention.tests.c:ccv_decimal_point
    Unexecuted instantiation: autograd.tests.c:ccv_decimal_point
    Unexecuted instantiation: autograd.vector.tests.c:ccv_decimal_point
    Unexecuted instantiation: backward.tests.c:ccv_decimal_point
    Unexecuted instantiation: batch.norm.tests.c:ccv_decimal_point
    Unexecuted instantiation: broadcast.tests.c:ccv_decimal_point
    Unexecuted instantiation: case_of.backward.tests.c:ccv_decimal_point
    Unexecuted instantiation: case_of.tests.c:ccv_decimal_point
    Unexecuted instantiation: cblas.tests.c:ccv_decimal_point
    Unexecuted instantiation: complex.tests.c:ccv_decimal_point
    Unexecuted instantiation: crossentropy.tests.c:ccv_decimal_point
    Unexecuted instantiation: custom.tests.c:ccv_decimal_point
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_decimal_point
    Unexecuted instantiation: dataframe.tests.c:ccv_decimal_point
    Unexecuted instantiation: dropout.tests.c:ccv_decimal_point
    Unexecuted instantiation: forward.tests.c:ccv_decimal_point
    Unexecuted instantiation: gemm.tests.c:ccv_decimal_point
    Unexecuted instantiation: gradient.tests.c:ccv_decimal_point
    Unexecuted instantiation: graph.io.tests.c:ccv_decimal_point
    Unexecuted instantiation: graph.tests.c:ccv_decimal_point
    Unexecuted instantiation: group.norm.tests.c:ccv_decimal_point
    Unexecuted instantiation: histogram.tests.c:ccv_decimal_point
    Unexecuted instantiation: layer.norm.tests.c:ccv_decimal_point
    Unexecuted instantiation: micro.tests.c:ccv_decimal_point
    Unexecuted instantiation: minimize.tests.c:ccv_decimal_point
    Unexecuted instantiation: numa.tests.c:ccv_decimal_point
    Unexecuted instantiation: rand.tests.c:ccv_decimal_point
    Unexecuted instantiation: rmsnorm.tests.c:ccv_decimal_point
    Unexecuted instantiation: simplify.tests.c:ccv_decimal_point
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_decimal_point
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_decimal_point
    Unexecuted instantiation: tape.tests.c:ccv_decimal_point
    Unexecuted instantiation: tensor.bind.tests.c:ccv_decimal_point
    Unexecuted instantiation: tfb.tests.c:ccv_decimal_point
    Unexecuted instantiation: while.backward.tests.c:ccv_decimal_point
    Unexecuted instantiation: while.tests.c:ccv_decimal_point
    Unexecuted instantiation: winograd.tests.c:ccv_decimal_point
    Unexecuted instantiation: numeric.tests.c:ccv_decimal_point
    Unexecuted instantiation: output.tests.c:ccv_decimal_point
    Unexecuted instantiation: util.tests.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cache.c:ccv_decimal_point
    Unexecuted instantiation: ccv_memory.c:ccv_decimal_point
    Unexecuted instantiation: ccv_io.c:ccv_decimal_point
    Unexecuted instantiation: ccv_numeric.c:ccv_decimal_point
    Unexecuted instantiation: ccv_algebra.c:ccv_decimal_point
    Unexecuted instantiation: ccv_util.c:ccv_decimal_point
    Unexecuted instantiation: ccv_basic.c:ccv_decimal_point
    Unexecuted instantiation: ccv_image_processing.c:ccv_decimal_point
    Unexecuted instantiation: ccv_resample.c:ccv_decimal_point
    Unexecuted instantiation: ccv_transform.c:ccv_decimal_point
    Unexecuted instantiation: ccv_classic.c:ccv_decimal_point
    Unexecuted instantiation: ccv_convnet.c:ccv_decimal_point
    Unexecuted instantiation: ccv_output.c:ccv_decimal_point
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_decimal_point
    Unexecuted instantiation: co.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_decimal_point
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_decimal_point
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_decimal_point
    Unexecuted instantiation: ccv_nnc_util.c:ccv_decimal_point
    1057
    1058
    typedef struct {
    1059
      float x, y, a, b;
    1060
      float roll, pitch, yaw;
    1061
    } ccv_decimal_pose_t;
    1062
    1063
    inline static ccv_decimal_pose_t ccv_decimal_pose(float x, float y, float a, float b, float roll, float pitch, float yaw)
    1064
    0
    {
    1065
    0
      ccv_decimal_pose_t pose;
    1066
    0
      pose.x = x;
    1067
    0
      pose.y = y;
    1068
    0
      pose.a = a;
    1069
    0
      pose.b = b;
    1070
    0
      pose.roll = roll;
    1071
    0
      pose.pitch = pitch;
    1072
    0
      pose.yaw = yaw;
    1073
    0
      return pose;
    1074
    0
    }
    Unexecuted instantiation: adam.tests.c:ccv_decimal_pose
    Unexecuted instantiation: cifar.tests.c:ccv_decimal_pose
    Unexecuted instantiation: cnnp.core.tests.c:ccv_decimal_pose
    Unexecuted instantiation: compare.tests.c:ccv_decimal_pose
    Unexecuted instantiation: compression.tests.c:ccv_decimal_pose
    Unexecuted instantiation: concat.tests.c:ccv_decimal_pose
    Unexecuted instantiation: cublas.tests.c:ccv_decimal_pose
    Unexecuted instantiation: cudnn.tests.c:ccv_decimal_pose
    Unexecuted instantiation: datatype.tests.c:ccv_decimal_pose
    Unexecuted instantiation: dense.net.tests.c:ccv_decimal_pose
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_decimal_pose
    Unexecuted instantiation: gelu.tests.c:ccv_decimal_pose
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_decimal_pose
    Unexecuted instantiation: imdb.tests.c:ccv_decimal_pose
    Unexecuted instantiation: index.tests.c:ccv_decimal_pose
    Unexecuted instantiation: lamb.tests.c:ccv_decimal_pose
    Unexecuted instantiation: leaky_relu.tests.c:ccv_decimal_pose
    Unexecuted instantiation: loss.tests.c:ccv_decimal_pose
    Unexecuted instantiation: lstm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: mpsblas.tests.c:ccv_decimal_pose
    Unexecuted instantiation: mpsdnn.tests.c:ccv_decimal_pose
    Unexecuted instantiation: nccl.tests.c:ccv_decimal_pose
    Unexecuted instantiation: nms.tests.c:ccv_decimal_pose
    Unexecuted instantiation: pad.tests.c:ccv_decimal_pose
    Unexecuted instantiation: palettize.tests.c:ccv_decimal_pose
    Unexecuted instantiation: parallel.tests.c:ccv_decimal_pose
    Unexecuted instantiation: partition.tests.c:ccv_decimal_pose
    Unexecuted instantiation: random.tests.c:ccv_decimal_pose
    Unexecuted instantiation: reduce.tests.c:ccv_decimal_pose
    Unexecuted instantiation: rmsprop.tests.c:ccv_decimal_pose
    Unexecuted instantiation: roi_align.tests.c:ccv_decimal_pose
    Unexecuted instantiation: scatter_add.tests.c:ccv_decimal_pose
    Unexecuted instantiation: schedule.tests.c:ccv_decimal_pose
    Unexecuted instantiation: sgd.tests.c:ccv_decimal_pose
    Unexecuted instantiation: smooth_l1.tests.c:ccv_decimal_pose
    Unexecuted instantiation: sort.tests.c:ccv_decimal_pose
    Unexecuted instantiation: swish.tests.c:ccv_decimal_pose
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_decimal_pose
    Unexecuted instantiation: tensor.tests.c:ccv_decimal_pose
    Unexecuted instantiation: transform.tests.c:ccv_decimal_pose
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_decimal_pose
    Unexecuted instantiation: upsample.tests.c:ccv_decimal_pose
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_decimal_pose
    Unexecuted instantiation: 3rdparty.tests.c:ccv_decimal_pose
    Unexecuted instantiation: algebra.tests.c:ccv_decimal_pose
    Unexecuted instantiation: basic.tests.c:ccv_decimal_pose
    Unexecuted instantiation: convnet.tests.c:ccv_decimal_pose
    Unexecuted instantiation: image_processing.tests.c:ccv_decimal_pose
    Unexecuted instantiation: io.tests.c:ccv_decimal_pose
    Unexecuted instantiation: memory.tests.c:ccv_decimal_pose
    Unexecuted instantiation: attention.tests.c:ccv_decimal_pose
    Unexecuted instantiation: autograd.tests.c:ccv_decimal_pose
    Unexecuted instantiation: autograd.vector.tests.c:ccv_decimal_pose
    Unexecuted instantiation: backward.tests.c:ccv_decimal_pose
    Unexecuted instantiation: batch.norm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: broadcast.tests.c:ccv_decimal_pose
    Unexecuted instantiation: case_of.backward.tests.c:ccv_decimal_pose
    Unexecuted instantiation: case_of.tests.c:ccv_decimal_pose
    Unexecuted instantiation: cblas.tests.c:ccv_decimal_pose
    Unexecuted instantiation: complex.tests.c:ccv_decimal_pose
    Unexecuted instantiation: crossentropy.tests.c:ccv_decimal_pose
    Unexecuted instantiation: custom.tests.c:ccv_decimal_pose
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_decimal_pose
    Unexecuted instantiation: dataframe.tests.c:ccv_decimal_pose
    Unexecuted instantiation: dropout.tests.c:ccv_decimal_pose
    Unexecuted instantiation: forward.tests.c:ccv_decimal_pose
    Unexecuted instantiation: gemm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: gradient.tests.c:ccv_decimal_pose
    Unexecuted instantiation: graph.io.tests.c:ccv_decimal_pose
    Unexecuted instantiation: graph.tests.c:ccv_decimal_pose
    Unexecuted instantiation: group.norm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: histogram.tests.c:ccv_decimal_pose
    Unexecuted instantiation: layer.norm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: micro.tests.c:ccv_decimal_pose
    Unexecuted instantiation: minimize.tests.c:ccv_decimal_pose
    Unexecuted instantiation: numa.tests.c:ccv_decimal_pose
    Unexecuted instantiation: rand.tests.c:ccv_decimal_pose
    Unexecuted instantiation: rmsnorm.tests.c:ccv_decimal_pose
    Unexecuted instantiation: simplify.tests.c:ccv_decimal_pose
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_decimal_pose
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_decimal_pose
    Unexecuted instantiation: tape.tests.c:ccv_decimal_pose
    Unexecuted instantiation: tensor.bind.tests.c:ccv_decimal_pose
    Unexecuted instantiation: tfb.tests.c:ccv_decimal_pose
    Unexecuted instantiation: while.backward.tests.c:ccv_decimal_pose
    Unexecuted instantiation: while.tests.c:ccv_decimal_pose
    Unexecuted instantiation: winograd.tests.c:ccv_decimal_pose
    Unexecuted instantiation: numeric.tests.c:ccv_decimal_pose
    Unexecuted instantiation: output.tests.c:ccv_decimal_pose
    Unexecuted instantiation: util.tests.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cache.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_memory.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_io.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_numeric.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_algebra.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_util.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_basic.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_image_processing.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_resample.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_transform.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_classic.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_convnet.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_output.c:ccv_decimal_pose
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_decimal_pose
    Unexecuted instantiation: co.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_decimal_pose
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_decimal_pose
    Unexecuted instantiation: ccv_nnc_util.c:ccv_decimal_pose
    1075
    1076
    typedef struct {
    1077
      ccv_rect_t rect;
    1078
      int size;
    1079
      ccv_array_t* set;
    1080
      long m10, m01, m11, m20, m02;
    1081
    } ccv_contour_t;
    1082
    1083
    /**
    1084
     * Create a new contour object.
    1085
     * @param set The initial capacity of the contour.
    1086
     */
    1087
    ccv_contour_t* ccv_contour_new(int set);
    1088
    /**
    1089
     * Push a point into the contour object.
    1090
     * @param contour The contour.
    1091
     * @param point The point.
    1092
     */
    1093
    void ccv_contour_push(ccv_contour_t* contour, ccv_point_t point);
    1094
    /**
    1095
     * Free up the contour object.
    1096
     * @param contour The contour.
    1097
     */
    1098
    void ccv_contour_free(ccv_contour_t* contour);
    1099
    /** @} */
    1100
    1101
    /* numerical algorithms ccv_numeric.c */
    1102
    /**
    1103
     * @defgroup ccv_numeric numerical algorithms
    1104
     * @{
    1105
     */
    1106
    1107
    /* clarification about algebra and numerical algorithms:
    1108
     * when using the word "algebra", I assume the operation is well established in Mathematic sense
    1109
     * and can be calculated with a straight-forward, finite sequence of operation. The "numerical"
    1110
     * in other word, refer to a class of algorithm that can only approximate/or iteratively found the
    1111
     * solution. Thus, "invert" would be classified as numerical because of the sense that in some case,
    1112
     * it can only be "approximate" (in least-square sense), so to "solve". */
    1113
    1114
    void ccv_invert(ccv_matrix_t* a, ccv_matrix_t** b, int type);
    1115
    void ccv_solve(ccv_matrix_t* a, ccv_matrix_t* b, ccv_matrix_t** d, int type);
    1116
    void ccv_eigen(ccv_dense_matrix_t* a, ccv_dense_matrix_t** vector, ccv_dense_matrix_t** lambda, int type, double epsilon);
    1117
    1118
    typedef struct {
    1119
      double interp; /**< Interpolate value. */
    1120
      double extrap; /**< Extrapolate value. */
    1121
      int max_iter; /**< Maximum iterations. */
    1122
      double ratio; /**< Increase ratio. */
    1123
      double rho; /**< Decrease ratio. */
    1124
      double sig; /**< Sigma. */
    1125
    } ccv_minimize_param_t;
    1126
    1127
    extern const ccv_minimize_param_t ccv_minimize_default_params;
    1128
    1129
    typedef int(*ccv_minimize_f)(const ccv_dense_matrix_t* x, double* f, ccv_dense_matrix_t* df, void*);
    1130
    /**
    1131
     * Linear-search to minimize function with partial derivatives. It is formed after [minimize.m](http://www.gatsby.ucl.ac.uk/~edward/code/minimize/example.html).
    1132
     * @param x The input vector.
    1133
     * @param length The length of line.
    1134
     * @param red The step size.
    1135
     * @param func (int ccv_minimize_f)(const ccv_dense_matrix_t* x, double* f, ccv_dense_matrix_t* df, void* data). Compute the function value, and its partial derivatives.
    1136
     * @param params A **ccv_minimize_param_t** structure that defines various aspect of the minimize function.
    1137
     * @param data Any extra user data.
    1138
     */
    1139
    void ccv_minimize(ccv_dense_matrix_t* x, int length, double red, ccv_minimize_f func, ccv_minimize_param_t params, void* data);
    1140
    /**
    1141
     * Convolve on dense matrix a with dense matrix b. This function has a soft dependency on [FFTW3](http://fftw.org/). If no FFTW3 exists, ccv will use [KissFFT](http://sourceforge.net/projects/kissfft/) shipped with it. FFTW3 is about 35% faster than KissFFT.
    1142
     * @param a Dense matrix a.
    1143
     * @param b Dense matrix b.
    1144
     * @param d The output matrix.
    1145
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1146
     * @param padding_pattern ccv doesn't support padding pattern for now.
    1147
     */
    1148
    void ccv_filter(ccv_dense_matrix_t* a, ccv_dense_matrix_t* b, ccv_dense_matrix_t** d, int type, int padding_pattern);
    1149
    typedef double(*ccv_filter_kernel_f)(double x, double y, void*);
    1150
    /**
    1151
     * Fill a given dense matrix with a kernel function.
    1152
     * @param x The matrix to be filled with.
    1153
     * @param func (double ccv_filter_kernel_f(double x, double y, void* data), compute the value with given x, y.
    1154
     * @param data Any extra user data.
    1155
     */
    1156
    void ccv_filter_kernel(ccv_dense_matrix_t* x, ccv_filter_kernel_f func, void* data);
    1157
    1158
    /* modern numerical algorithms */
    1159
    /**
    1160
     * [Distance transform](https://en.wikipedia.org/wiki/Distance_transform). The current implementation follows [Distance Transforms of Sampled Functions](http://www.cs.cornell.edu/~dph/papers/dt.pdf). The dynamic programming technique has O(n) time complexity.
    1161
     * @param a The input matrix.
    1162
     * @param b The output matrix.
    1163
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1164
     * @param x The x coordinate offset.
    1165
     * @param x_type The type of output x coordinate offset, if 0, ccv will default to CCV_32S | CCV_C1.
    1166
     * @param y The y coordinate offset.
    1167
     * @param y_type The type of output x coordinate offset, if 0, ccv will default to CCV_32S | CCV_C1.
    1168
     * @param dx The x coefficient.
    1169
     * @param dy The y coefficient.
    1170
     * @param dxx The x^2 coefficient.
    1171
     * @param dyy The y^2 coefficient.
    1172
     * @param flag CCV_GSEDT, generalized squared Euclidean distance transform. CCV_NEGATIVE, negate value in input matrix for computation; effectively, this enables us to compute the maximum distance transform rather than minimum (default one).
    1173
     */
    1174
    void ccv_distance_transform(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, ccv_dense_matrix_t** x, int x_type, ccv_dense_matrix_t** y, int y_type, double dx, double dy, double dxx, double dyy, int flag);
    1175
    /**
    1176
     * [O(kn) K-means 1D](https://arxiv.org/pdf/1701.07204.pdf). This implementation follows https://github.com/dstein64/kmeans1d/blob/master/kmeans1d/_core.cpp but makes upfront allocations rather than multiple allocations during the reduce operation.  This implementation uses O(kn) memory, due to we keep backtracking of T.
    1177
     * @param a The input matrix, can be 16F, 32F or 64F.
    1178
     * @param k The number of clusters, should be larger than 1.
    1179
     * @param clusters The index into each cluster.
    1180
     * @param centroids The center of each cluster.
    1181
     */
    1182
    void ccv_kmeans1d(const ccv_dense_matrix_t* const a, const int k, int* const clusters, double* const centroids);
    1183
    /** @} */
    1184
    void ccv_sparse_coding(ccv_matrix_t* x, int k, ccv_matrix_t** A, int typeA, ccv_matrix_t** y, int typey);
    1185
    void ccv_compressive_sensing_reconstruct(ccv_matrix_t* a, ccv_matrix_t* x, ccv_matrix_t** y, int type);
    1186
    1187
    /**
    1188
     * @defgroup ccv_basic basic image pre-processing utilities
    1189
     * The utilities in this file provides basic pre-processing which, most-likely, are the first steps for computer vision algorithms.
    1190
     * @{
    1191
     */
    1192
    1193
    /**
    1194
     * Compute image with [Sobel operator](https://en.wikipedia.org/wiki/Sobel_operator).
    1195
     * @param a The input matrix.
    1196
     * @param b The output matrix.
    1197
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1198
     * @param dx The window size of Sobel operator on x-axis, specially optimized for 1, 3
    1199
     * @param dy The window size of Sobel operator on y-axis, specially optimized for 1, 3
    1200
     */
    1201
    void ccv_sobel(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int dx, int dy);
    1202
    /**
    1203
     * Compute the gradient (angle and magnitude) at each pixel.
    1204
     * @param a The input matrix.
    1205
     * @param theta The output matrix of angle at each pixel.
    1206
     * @param ttype The type of output matrix, if 0, ccv will defaults to CCV_32F.
    1207
     * @param m The output matrix of magnitude at each pixel.
    1208
     * @param mtype The type of output matrix, if 0, ccv will defaults to CCV_32F.
    1209
     * @param dx The window size of the underlying Sobel operator used on x-axis, specially optimized for 1, 3
    1210
     * @param dy The window size of the underlying Sobel operator used on y-axis, specially optimized for 1, 3
    1211
     */
    1212
    void ccv_gradient(ccv_dense_matrix_t* a, ccv_dense_matrix_t** theta, int ttype, ccv_dense_matrix_t** m, int mtype, int dx, int dy);
    1213
    1214
    enum {
    1215
      CCV_FLIP_X = 0x01,
    1216
      CCV_FLIP_Y = 0x02,
    1217
    };
    1218
    /**
    1219
     * Flip the matrix by x-axis, y-axis or both.
    1220
     * @param a The input matrix.
    1221
     * @param b The output matrix (it is in-place safe).
    1222
     * @param btype The type of output matrix, if 0, ccv will use the sample type as the input matrix.
    1223
     * @param type CCV_FLIP_X - flip around x-axis, CCV_FLIP_Y - flip around y-axis.
    1224
     */
    1225
    void ccv_flip(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int btype, int type);
    1226
    /**
    1227
     * Using [Gaussian blur](https://en.wikipedia.org/wiki/Gaussian_blur) on a given matrix. It implements a O(n * sqrt(m)) algorithm, n is the size of input matrix, m is the size of Gaussian filtering kernel.
    1228
     * @param a The input matrix.
    1229
     * @param b The output matrix.
    1230
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1231
     * @param sigma The sigma factor in Gaussian filtering kernel.
    1232
     */
    1233
    void ccv_blur(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, double sigma);
    1234
    /**
    1235
     * Perform morphologic operation on the given matrix. It implements separable min filter for erode. Thus, the size shape is rectangle.
    1236
     * @param a The input matrix.
    1237
     * @param b The output matrix.
    1238
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1239
     * @param size The size of this operation. 3 is usually a good choice.
    1240
     */
    1241
    void ccv_erode(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int size);
    1242
    /**
    1243
     * Perform morphologic operation on the given matrix. It implements separable max filter for dilate. Thus, the size shape is rectangle.
    1244
     * @param a The input matrix.
    1245
     * @param b The output matrix.
    1246
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1247
     * @param size The size of this operation. 3 is usually a good choice.
    1248
     */
    1249
    void ccv_dilate(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int size);
    1250
    1251
    /** @} */
    1252
    1253
    /**
    1254
     * @defgroup ccv_image_processing image processing utilities
    1255
     * The utilities in this file provides image processing methods that are widely used for image enhancements.
    1256
     * @{
    1257
     */
    1258
    1259
    enum {
    1260
      CCV_RGB_TO_YUV = 0x01,
    1261
    };
    1262
    1263
    /**
    1264
     * Convert matrix from one color space representation to another.
    1265
     * @param a The input matrix.
    1266
     * @param b The output matrix.
    1267
     * @param type The type of output matrix, if 0, ccv will use the sample type as the input matrix.
    1268
     * @param flag **CCV_RGB_TO_YUV** to convert from RGB color space to YUV color space.
    1269
     */
    1270
    void ccv_color_transform(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int flag);
    1271
    /**
    1272
     * Manipulate image's saturation.
    1273
     * @param a The input matrix.
    1274
     * @param b The output matrix (it is in-place safe).
    1275
     * @param type The type of output matrix, if 0, ccv will use the sample type as the input matrix.
    1276
     * @param ds The coefficient (0: grayscale, 1: original).
    1277
     */
    1278
    void ccv_saturation(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, double ds);
    1279
    /**
    1280
     * Manipulate image's contrast.
    1281
     * @param a The input matrix.
    1282
     * @param b The output matrix (it is in-place safe).
    1283
     * @param type The type of output matrix, if 0, ccv will use the sample type as the input matrix.
    1284
     * @param ds The coefficient (0: mean image, 1: original).
    1285
     */
    1286
    void ccv_contrast(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, double ds);
    1287
    /** @} */
    1288
    1289
    /**
    1290
     * @defgroup ccv_resample image resampling utilities
    1291
     * @{
    1292
     */
    1293
    1294
    enum {
    1295
      CCV_INTER_AREA    = 0x01,
    1296
      CCV_INTER_LINEAR  = 0X02,
    1297
      CCV_INTER_CUBIC   = 0X04,
    1298
      CCV_INTER_LANCZOS = 0X08,
    1299
    };
    1300
    1301
    /**
    1302
     * Resample a given matrix to different size, as for now, ccv only supports either downsampling (with CCV_INTER_AREA) or upsampling (with CCV_INTER_CUBIC).
    1303
     * @param a The input matrix.
    1304
     * @param b The output matrix.
    1305
     * @param btype The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1306
     * @param rows_scale The scale factor for rows. The number of rows, if not provided, will be computed as round(rows * rows_scale)
    1307
     * @param cols_scale The scale factor for columns. The number of columns, if not provided, will be computed as round(columns * columns_scale)
    1308
     * @param type For now, ccv supports CCV_INTER_AREA, which is an extension to [bilinear resampling](https://en.wikipedia.org/wiki/Bilinear_filtering) for downsampling and CCV_INTER_CUBIC [bicubic resampling](https://en.wikipedia.org/wiki/Bicubic_interpolation) for upsampling.
    1309
     */
    1310
    void ccv_resample(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int btype, double rows_scale, double cols_scale, int type);
    1311
    /**
    1312
     * Downsample a given matrix to exactly half size with a [Gaussian filter](https://en.wikipedia.org/wiki/Gaussian_filter). The half size is approximated by floor(rows * 0.5) x floor(cols * 0.5).
    1313
     * @param a The input matrix.
    1314
     * @param b The output matrix.
    1315
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1316
     * @param src_x Shift the start point by src_x.
    1317
     * @param src_y Shift the start point by src_y.
    1318
     */
    1319
    void ccv_sample_down(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int src_x, int src_y);
    1320
    /**
    1321
     * Upsample a given matrix to exactly double size with a [Gaussian filter](https://en.wikipedia.org/wiki/Gaussian_filter).
    1322
     * @param a The input matrix.
    1323
     * @param b The output matrix.
    1324
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1325
     * @param src_x Shift the start point by src_x.
    1326
     * @param src_y Shift the start point by src_y.
    1327
     */
    1328
    void ccv_sample_up(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int src_x, int src_y);
    1329
    /** @} */
    1330
    1331
    /**
    1332
     * @defgroup ccv_transform image transform utilities
    1333
     * @{
    1334
     */
    1335
    1336
    /**
    1337
     * Similar to ccv_slice, it will slice a given matrix into required rows / cols, but it will interpolate the value with bilinear filter if x and y is non-integer.
    1338
     * @param a The given matrix that will be sliced
    1339
     * @param b The output matrix
    1340
     * @param type The type of output matrix
    1341
     * @param y The top point to slice
    1342
     * @param x The left point to slice
    1343
     * @param rows The number of rows for destination matrix
    1344
     * @param cols The number of cols for destination matrix
    1345
     */
    1346
    void ccv_decimal_slice(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, float y, float x, int rows, int cols);
    1347
    /**
    1348
     * Apply a [3D transform](https://en.wikipedia.org/wiki/Perspective_transform#Perspective_projection) against the given point in a given image size, assuming field of view is 60 (in degree).
    1349
     * @param point The point to be transformed in decimal
    1350
     * @param size The image size
    1351
     * @param m00, m01, m02, m10, m11, m12, m20, m21, m22 The transformation matrix
    1352
     */
    1353
    ccv_decimal_point_t ccv_perspective_transform_apply(ccv_decimal_point_t point, ccv_size_t size, float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22);
    1354
    /**
    1355
     * Apply a [3D transform](https://en.wikipedia.org/wiki/Perspective_transform#Perspective_projection) on a given matrix, assuming field of view is 60 (in degree).
    1356
     * @param a The given matrix to be transformed
    1357
     * @param b The output matrix
    1358
     * @param type The type of output matrix
    1359
     * @param m00, m01, m02, m10, m11, m12, m20, m21, m22 The transformation matrix
    1360
     */
    1361
    void ccv_perspective_transform(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22);
    1362
    /** @} */
    1363
    1364
    /* classic computer vision algorithms ccv_classic.c */
    1365
    /**
    1366
     * @defgroup ccv_classic classic computer vision algorithms
    1367
     * @{
    1368
     */
    1369
    1370
    /**
    1371
     * [Histogram-of-Oriented-Gradients](https://en.wikipedia.org/wiki/Histogram_of_oriented_gradients) implementation, specifically, it implements the HOG described in *Object Detection with Discriminatively Trained Part-Based Models, Pedro F. Felzenszwalb, Ross B. Girshick, David McAllester and Deva Ramanan*.
    1372
     * @param a The input matrix.
    1373
     * @param b The output matrix.
    1374
     * @param b_type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1375
     * @param sbin The number of bins for orientation (default to 9, thus, for **b**, it will have 9 * 2 + 9 + 4 = 31 channels).
    1376
     * @param size The window size for HOG (default to 8)
    1377
     */
    1378
    void ccv_hog(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int b_type, int sbin, int size);
    1379
    /**
    1380
     * [Canny edge detector](https://en.wikipedia.org/wiki/Canny_edge_detector) implementation. For performance reason, this is a clean-up reimplementation of OpenCV's Canny edge detector, it has very similar performance characteristic as the OpenCV one. As of today, ccv's Canny edge detector only works with CCV_8U or CCV_32S dense matrix type.
    1381
     * @param a The input matrix.
    1382
     * @param b The output matrix.
    1383
     * @param type The type of output matrix, if 0, ccv will create a CCV_8U | CCV_C1 matrix.
    1384
     * @param size The underlying Sobel filter size.
    1385
     * @param low_thresh The low threshold that makes the point interesting.
    1386
     * @param high_thresh The high threshold that makes the point acceptable.
    1387
     */
    1388
    void ccv_canny(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, int size, double low_thresh, double high_thresh);
    1389
    void ccv_close_outline(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type);
    1390
    /* range: exclusive, return value: inclusive (i.e., threshold = 5, 0~5 is background, 6~range-1 is foreground */
    1391
    /**
    1392
     * [OTSU](https://en.wikipedia.org/wiki/Otsu%27s_method) implementation.
    1393
     * @param a The input matrix.
    1394
     * @param outvar The inter-class variance.
    1395
     * @param range The maximum range of data in the input matrix.
    1396
     * @return The threshold, inclusively. e.g. 5 means 0~5 is in the background, and 6~255 is in the foreground.
    1397
     */
    1398
    int ccv_otsu(ccv_dense_matrix_t* a, double* outvar, int range);
    1399
    1400
    typedef struct {
    1401
      ccv_decimal_point_t point;
    1402
      uint8_t status;
    1403
    } ccv_decimal_point_with_status_t;
    1404
    1405
    /**
    1406
     * [Lucas Kanade](https://en.wikipedia.org/wiki/Lucas%E2%80%93Kanade_Optical_Flow_Method) optical flow implementation with image pyramid extension.
    1407
     * @param a The first frame
    1408
     * @param b The next frame
    1409
     * @param point_a The points in first frame, of **ccv_decimal_point_t** type
    1410
     * @param point_b The output points in the next frame, of **ccv_decimal_point_with_status_t** type
    1411
     * @param win_size The window size to compute each optical flow, it must be a odd number
    1412
     * @param level How many image pyramids to be used for the computation
    1413
     * @param min_eigen The minimal eigen-value to pass optical flow computation
    1414
     */
    1415
    void ccv_optical_flow_lucas_kanade(ccv_dense_matrix_t* a, ccv_dense_matrix_t* b, ccv_array_t* point_a, ccv_array_t** point_b, ccv_size_t win_size, int level, double min_eigen);
    1416
    /** @} */
    1417
    1418
    /* modern computer vision algorithms */
    1419
    /* SIFT, DAISY, SWT, MSER, DPM, BBF, SGF, SSD, FAST */
    1420
    1421
    /**
    1422
     * @defgroup ccv_daisy DAISY
    1423
     * @{
    1424
     */
    1425
    1426
    /* daisy related methods */
    1427
    typedef struct {
    1428
      double radius; /**< the Gaussian radius. */
    1429
      int rad_q_no;
    1430
      int th_q_no;
    1431
      int hist_th_q_no;
    1432
      float normalize_threshold;
    1433
      int normalize_method;
    1434
    } ccv_daisy_param_t;
    1435
    1436
    enum {
    1437
      CCV_DAISY_NORMAL_PARTIAL = 0x01,
    1438
      CCV_DAISY_NORMAL_FULL    = 0x02,
    1439
      CCV_DAISY_NORMAL_SIFT    = 0x03,
    1440
    };
    1441
    1442
    /**
    1443
     * [DAISY](http://cvlab.epfl.ch/publications/publications/2010/TolaLF10a.pdf) implementation. For more details - DAISY: An Efficient Dense Descriptor Applied to Wide-Baseline Stereo.
    1444
     * @param a The input matrix.
    1445
     * @param b The output matrix.
    1446
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    1447
     * @param params A **ccv_daisy_param_t** structure that defines various aspect of the feature extractor.
    1448
     */
    1449
    void ccv_daisy(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, ccv_daisy_param_t params);
    1450
    /** @} */
    1451
    1452
    /* sift related methods */
    1453
    /**
    1454
     * @defgroup ccv_sift scale invariant feature transform
    1455
     * @{
    1456
     */
    1457
    typedef struct {
    1458
      float x, y;
    1459
      int octave;
    1460
      int level;
    1461
      union {
    1462
        struct {
    1463
          double a, b;
    1464
          double c, d;
    1465
        } affine;
    1466
        struct {
    1467
          double scale;
    1468
          double angle;
    1469
        } regular;
    1470
      };
    1471
    } ccv_keypoint_t;
    1472
    1473
    typedef struct {
    1474
      int up2x; /**< If upscale the image for better SIFT accuracy. */
    1475
      int noctaves; /**< Number of octaves. */
    1476
      int nlevels; /**< Number of levels for each octaves. */
    1477
      float edge_threshold; /**< Above this threshold, it will be recognized as edge otherwise be ignored. */
    1478
      float peak_threshold; /**< Above this threshold, it will be recognized as potential feature point. */
    1479
      float norm_threshold; /**< If norm of the descriptor is smaller than threshold, it will be ignored. */
    1480
    } ccv_sift_param_t;
    1481
    1482
    extern const ccv_sift_param_t ccv_sift_default_params;
    1483
    1484
    /**
    1485
     * Compute [SIFT](https://en.wikipedia.org/wiki/Scale-invariant_feature_transform) key-points.
    1486
     * @param a The input matrix.
    1487
     * @param keypoints The array of key-points, a ccv_keypoint_t structure.
    1488
     * @param desc The descriptor for each key-point.
    1489
     * @param type The type of the descriptor, if 0, ccv will default to CCV_32F.
    1490
     * @param params A **ccv_sift_param_t** structure that defines various aspect of SIFT function.
    1491
     */
    1492
    void ccv_sift(ccv_dense_matrix_t* a, ccv_array_t** keypoints, ccv_dense_matrix_t** desc, int type, ccv_sift_param_t params);
    1493
    /** @} */
    1494
    1495
    /* mser related method */
    1496
    1497
    typedef struct {
    1498
      /* parameters for MSER */
    1499
      int delta;
    1500
      int min_area; /* default: 60 */
    1501
      int direction; /* default: 0, 0 for both, -1 for bright to dark, 1 for dark to bright */
    1502
      int max_area;
    1503
      double max_variance;
    1504
      double min_diversity;
    1505
      int range; /* from 0 to range, inclusive */
    1506
      /* parameters for MSCR */
    1507
      double area_threshold; /* default: 1.01 */
    1508
      double min_margin; /* default: 0.003 */
    1509
      int max_evolution;
    1510
      double edge_blur_sigma; /* default: 1.0 */
    1511
    } ccv_mser_param_t;
    1512
    1513
    typedef struct {
    1514
      ccv_rect_t rect;
    1515
      int size;
    1516
      long m10, m01, m11, m20, m02;
    1517
      ccv_point_t keypoint;
    1518
    } ccv_mser_keypoint_t;
    1519
    1520
    enum {
    1521
      CCV_BRIGHT_TO_DARK = -1,
    1522
      CCV_DARK_TO_BRIGHT = 1,
    1523
    };
    1524
    1525
    CCV_WARN_UNUSED(ccv_array_t*) ccv_mser(ccv_dense_matrix_t* a, ccv_dense_matrix_t* h, ccv_dense_matrix_t** b, int type, ccv_mser_param_t params);
    1526
    1527
    /* swt related method: stroke width transform is relatively new, typically used in text detection */
    1528
    /**
    1529
     * @defgroup ccv_swt stroke width transform
    1530
     * @{
    1531
     */
    1532
    typedef struct {
    1533
      int interval; /**< Intervals for scale invariant option. */
    1534
      int min_neighbors; /**< Minimal neighbors to make a detection valid, this is for scale-invariant version. */
    1535
      int scale_invariant; /**< Enable scale invariant swt (to scale to different sizes and then combine the results) */
    1536
      int direction; /**< SWT direction. (black to white or white to black). */
    1537
      double same_word_thresh[2]; /**< Overlapping more than 0.1 of the bigger one (0), and 0.9 of the smaller one (1) */
    1538
      /**
    1539
       * @name Canny parameters
    1540
       * @{
    1541
       */
    1542
      int size; /**< Parameters for [Canny edge detector](/lib/ccv-classic). */
    1543
      int low_thresh; /**< Parameters for [Canny edge detector](/lib/ccv-classic). */
    1544
      int high_thresh; /**< Parameters for [Canny edge detector](/lib/ccv-classic). */
    1545
      /** @} */
    1546
      /**
    1547
       * @name Geometry filtering parameters
    1548
       * @{
    1549
       */
    1550
      int max_height; /**< The maximum height for a letter. */
    1551
      int min_height; /**< The minimum height for a letter. */
    1552
      int min_area; /**< The minimum occupied area for a letter. */
    1553
      int letter_occlude_thresh;
    1554
      double aspect_ratio; /**< The maximum aspect ratio for a letter. */
    1555
      double std_ratio; /**< The inner-class standard derivation when grouping letters. */
    1556
      /** @} */
    1557
      /**
    1558
       * @name Grouping parameters
    1559
       * @{
    1560
       */
    1561
      double thickness_ratio; /**< The allowable thickness variance when grouping letters. */
    1562
      double height_ratio; /**< The allowable height variance when grouping letters. */
    1563
      int intensity_thresh; /**< The allowable intensity variance when grouping letters. */
    1564
      double distance_ratio; /**< The allowable distance variance when grouping letters. */
    1565
      double intersect_ratio; /**< The allowable intersect variance when grouping letters. */
    1566
      double elongate_ratio; /**< The allowable elongate variance when grouping letters. */
    1567
      int letter_thresh; /**< The allowable letter threshold. */
    1568
      /** @} */
    1569
      /**
    1570
       * @name Break textline into words
    1571
       * @{
    1572
       */
    1573
      int breakdown; /**< If breakdown text line into words. */
    1574
      double breakdown_ratio; /**< Apply [OSTU](/lib/ccv-classic) and if inter-class variance above the threshold, it will be break down into words. */
    1575
      /** @} */
    1576
    } ccv_swt_param_t;
    1577
    1578
    extern const ccv_swt_param_t ccv_swt_default_params;
    1579
    1580
    /**
    1581
     * Compute the Stroke-Width-Transform image.
    1582
     * @param a The input matrix.
    1583
     * @param b The output matrix.
    1584
     * @param type The type of the output matrix, if 0, ccv will default to CCV_32S | CCV_C1.
    1585
     * @param params A **ccv_swt_param_t** structure that defines various aspect of the SWT function.
    1586
     */
    1587
    void ccv_swt(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type, ccv_swt_param_t params);
    1588
    /**
    1589
     * Return array of regions that are potentially text area.
    1590
     * @param a The input matrix.
    1591
     * @param params A **ccv_swt_param_t** structure that defines various aspect of the SWT function.
    1592
     * @return A **ccv_array_t** of **ccv_comp_t** with detection results.
    1593
     */
    1594
    CCV_WARN_UNUSED(ccv_array_t*) ccv_swt_detect_words(ccv_dense_matrix_t* a, ccv_swt_param_t params);
    1595
    1596
    /* it makes sense now to include a simple data structure that encapsulate the common idiom of
    1597
     * having file name with a bounding box */
    1598
    1599
    typedef struct {
    1600
      char* filename;
    1601
      union {
    1602
        ccv_decimal_rect_t bbox;
    1603
        ccv_decimal_pose_t pose;
    1604
      };
    1605
    } ccv_file_info_t;
    1606
    1607
    /* I'd like to include Deformable Part Models as a general object detection method in here
    1608
     * The difference between BBF and DPM:
    1609
     * ~ BBF is for rigid object detection: banners, box, faces etc.
    1610
     * ~ DPM is more generalized, can detect people, car, bike (larger inner-class difference) etc.
    1611
     * ~ BBF is blazing fast (few milliseconds), DPM is relatively slow (around 1 seconds or so) */
    1612
    1613
    /**
    1614
     * @defgroup ccv_dpm deformable parts model
    1615
     * @{
    1616
     */
    1617
    1618
    #define CCV_DPM_PART_MAX (10)
    1619
    1620
    typedef struct {
    1621
      int id;
    1622
      float confidence;
    1623
    } ccv_classification_t;
    1624
    1625
    typedef struct {
    1626
      ccv_rect_t rect;
    1627
      int neighbors;
    1628
      ccv_classification_t classification;
    1629
    } ccv_comp_t;
    1630
    1631
    typedef struct {
    1632
      ccv_rect_t rect;
    1633
      int neighbors;
    1634
      ccv_classification_t classification;
    1635
      int pnum;
    1636
      ccv_comp_t part[CCV_DPM_PART_MAX];
    1637
    } ccv_root_comp_t;
    1638
    1639
    typedef struct {
    1640
      ccv_dense_matrix_t* w;
    1641
      double dx, dy, dxx, dyy;
    1642
      int x, y, z;
    1643
      int counterpart;
    1644
      float alpha[6];
    1645
    } ccv_dpm_part_classifier_t;
    1646
    1647
    typedef struct {
    1648
      int count;
    1649
      ccv_dpm_part_classifier_t root;
    1650
      ccv_dpm_part_classifier_t* part;
    1651
      float alpha[3], beta;
    1652
    } ccv_dpm_root_classifier_t;
    1653
    1654
    typedef struct {
    1655
      int count;
    1656
      ccv_dpm_root_classifier_t* root;
    1657
    } ccv_dpm_mixture_model_t;
    1658
    1659
    typedef struct {
    1660
      int interval; /**< Interval images between the full size image and the half size one. e.g. 2 will generate 2 images in between full size image and half size one: image with full size, image with 5/6 size, image with 2/3 size, image with 1/2 size. */
    1661
      int min_neighbors; /**< 0: no grouping afterwards. 1: group objects that intersects each other. > 1: group objects that intersects each other, and only passes these that have at least **min_neighbors** intersected objects. */
    1662
      int flags; /**< CCV_DPM_NO_NESTED, if one class of object is inside another class of object, this flag will reject the first object. */
    1663
      float threshold; /**< The threshold the determines the acceptance of an object. */
    1664
    } ccv_dpm_param_t;
    1665
    1666
    typedef struct {
    1667
      int components; /**< The number of root filters in the mixture model. */
    1668
      int parts; /**< The number of part filters for each root filter. */
    1669
      int grayscale; /**< Whether to exploit color in a given image. */
    1670
      int symmetric; /**< Whether to exploit symmetric property of the object. */
    1671
      int min_area; /**< The minimum area that one part classifier can occupy, 3000 is a reasonable number. */
    1672
      int max_area; /**< The maximum area that one part classifier can occupy. 5000 is a reasonable number. */
    1673
      int iterations; /**< How many iterations needed for stochastic gradient descent. */
    1674
      int data_minings; /**< How many data mining procedures are needed for discovering hard examples. */
    1675
      int root_relabels; /**< How many relabel procedures for root classifier are needed. */
    1676
      int relabels; /**< How many relabel procedures are needed. */
    1677
      int discard_estimating_constant; // 1
    1678
      int negative_cache_size; /**< The cache size for negative examples. 1000 is a reasonable number. */
    1679
      double include_overlap; /**< The percentage of overlap between expected bounding box and the bounding box from detection. Beyond this threshold, it is ensured to be the same object. 0.7 is a reasonable number. */
    1680
      double alpha; /**< The step size for stochastic gradient descent. */
    1681
      double alpha_ratio; /**< Decrease the step size for each iteration. 0.85 is a reasonable number. */
    1682
      double balance; /**< To balance the weight of positive examples and negative examples. 1.5 is a reasonable number. */
    1683
      double C; /**< C in SVM. */
    1684
      double percentile_breakdown; /**< The percentile use for breakdown threshold. 0.05 is the default. */
    1685
      ccv_dpm_param_t detector; /**< A **ccv_dpm_params_t** structure that will be used to search positive examples and negative examples from background images. */
    1686
    } ccv_dpm_new_param_t;
    1687
    1688
    enum {
    1689
      CCV_DPM_NO_NESTED = 0x10000000,
    1690
    };
    1691
    1692
    extern const ccv_dpm_param_t ccv_dpm_default_params;
    1693
    1694
    /**
    1695
     * Create a new DPM mixture model from given positive examples and background images. This function has hard dependencies on [GSL](http://www.gnu.org/software/gsl/) and [LibLinear](http://www.csie.ntu.edu.tw/~cjlin/liblinear/).
    1696
     * @param posfiles An array of positive images.
    1697
     * @param bboxes An array of bounding boxes for positive images.
    1698
     * @param posnum Number of positive examples.
    1699
     * @param bgfiles An array of background images.
    1700
     * @param bgnum Number of background images.
    1701
     * @param negnum Number of negative examples that is harvested from background images.
    1702
     * @param dir The working directory to store/retrieve intermediate data.
    1703
     * @param params A **ccv_dpm_new_param_t** structure that defines various aspects of the training function.
    1704
     */
    1705
    void ccv_dpm_mixture_model_new(char** posfiles, ccv_rect_t* bboxes, int posnum, char** bgfiles, int bgnum, int negnum, const char* dir, ccv_dpm_new_param_t params);
    1706
    /**
    1707
     * Using a DPM mixture model to detect objects in a given image. If you have several DPM mixture models, it is better to use them in one method call. In this way, ccv will try to optimize the overall performance.
    1708
     * @param a The input image.
    1709
     * @param model An array of mixture models.
    1710
     * @param count How many mixture models you've passed in.
    1711
     * @param params A **ccv_dpm_param_t** structure that defines various aspects of the detector.
    1712
     * @return A **ccv_array_t** of **ccv_root_comp_t** that contains the root bounding box as well as its parts.
    1713
     */
    1714
    CCV_WARN_UNUSED(ccv_array_t*) ccv_dpm_detect_objects(ccv_dense_matrix_t* a, ccv_dpm_mixture_model_t** model, int count, ccv_dpm_param_t params);
    1715
    /**
    1716
     * Read DPM mixture model from a model file.
    1717
     * @param directory The model file for DPM mixture model.
    1718
     * @return A DPM mixture model, 0 if no valid DPM mixture model available.
    1719
     */
    1720
    CCV_WARN_UNUSED(ccv_dpm_mixture_model_t*) ccv_dpm_read_mixture_model(const char* directory);
    1721
    /**
    1722
     * Free up the memory of DPM mixture model.
    1723
     * @param model The DPM mixture model.
    1724
     */
    1725
    void ccv_dpm_mixture_model_free(ccv_dpm_mixture_model_t* model);
    1726
    /** @} */
    1727
    1728
    /**
    1729
     * @defgroup ccv_bbf binary brightness feature
    1730
     * this is open source implementation of object detection algorithm: brightness binary feature
    1731
     * it is an extension/modification of original HAAR-like feature with Adaboost, featured faster
    1732
     * computation and higher accuracy (current highest accuracy close-source face detector is based
    1733
     * on the same algorithm)
    1734
     * @{
    1735
     */
    1736
    1737
    #define CCV_BBF_POINT_MAX (8)
    1738
    #define CCV_BBF_POINT_MIN (3)
    1739
    1740
    typedef struct {
    1741
      int size;
    1742
      int px[CCV_BBF_POINT_MAX];
    1743
      int py[CCV_BBF_POINT_MAX];
    1744
      int pz[CCV_BBF_POINT_MAX];
    1745
      int nx[CCV_BBF_POINT_MAX];
    1746
      int ny[CCV_BBF_POINT_MAX];
    1747
      int nz[CCV_BBF_POINT_MAX];
    1748
    } ccv_bbf_feature_t;
    1749
    1750
    typedef struct {
    1751
      int count;
    1752
      float threshold;
    1753
      ccv_bbf_feature_t* feature;
    1754
      float* alpha;
    1755
    } ccv_bbf_stage_classifier_t;
    1756
    1757
    typedef struct {
    1758
      int count;
    1759
      ccv_size_t size;
    1760
      ccv_bbf_stage_classifier_t* stage_classifier;
    1761
    } ccv_bbf_classifier_cascade_t;
    1762
    1763
    enum {
    1764
      CCV_BBF_GENETIC_OPT = 0x01,
    1765
      CCV_BBF_FLOAT_OPT = 0x02,
    1766
    };
    1767
    1768
    typedef struct {
    1769
      int interval; /**< Interval images between the full size image and the half size one. e.g. 2 will generate 2 images in between full size image and half size one: image with full size, image with 5/6 size, image with 2/3 size, image with 1/2 size. */
    1770
      int min_neighbors; /**< 0: no grouping afterwards. 1: group objects that intersects each other. > 1: group objects that intersects each other, and only passes these that have at least **min_neighbors** intersected objects. */
    1771
      int flags; /**< CCV_BBF_NO_NESTED, if one class of object is inside another class of object, this flag will reject the first object. */
    1772
      int accurate; /**< BBF will generates 4 spatial scale variations for better accuracy. Set this parameter to 0 will reduce to 1 scale variation, and thus 3 times faster but lower the general accuracy of the detector. */
    1773
      ccv_size_t size; /**< The smallest object size that will be interesting to us. */
    1774
    } ccv_bbf_param_t;
    1775
    1776
    typedef struct {
    1777
      double pos_crit; /**< Positive criteria or the targeted recall ratio, BBF classifier tries to adjust the constant to meet this criteria. */
    1778
      double neg_crit; /**< Negative criteria or the targeted reject ratio, BBF classifier tries to include more weak features until meet this criteria. */
    1779
      double balance_k; /**< Weight positive examples differently from negative examples. */
    1780
      int layer; /**< The maximum layer trained for the classifier cascade. */
    1781
      int feature_number; /**< The maximum feature number for each classifier. */
    1782
      int optimizer; /**< CCV_BBF_GENETIC_OPT, using genetic algorithm to search the best weak feature; CCV_BBF_FLOAT_OPT, using float search to improve the found best weak feature. */
    1783
      ccv_bbf_param_t detector; /**< A **ccv_bbf_params_t** structure that will be used to search negative examples from background images. */
    1784
    } ccv_bbf_new_param_t;
    1785
    1786
    enum {
    1787
      CCV_BBF_NO_NESTED = 0x10000000,
    1788
    };
    1789
    1790
    extern const ccv_bbf_param_t ccv_bbf_default_params;
    1791
    1792
    /**
    1793
     * Create a new BBF classifier cascade from given positive examples and background images. This function has a hard dependency on [GSL](http://www.gnu.org/software/gsl/).
    1794
     * @param posimg An array of positive examples.
    1795
     * @param posnum Number of positive examples.
    1796
     * @param bgfiles An array of background images.
    1797
     * @param bgnum Number of background images.
    1798
     * @param negnum Number of negative examples that is harvested from background images.
    1799
     * @param size The image size of positive examples.
    1800
     * @param dir The working directory to store/retrieve intermediate data.
    1801
     * @param params A **ccv_bbf_new_param_t** structure that defines various aspects of the training function.
    1802
     */
    1803
    void ccv_bbf_classifier_cascade_new(ccv_dense_matrix_t** posimg, int posnum, char** bgfiles, int bgnum, int negnum, ccv_size_t size, const char* dir, ccv_bbf_new_param_t params);
    1804
    /**
    1805
     * Using a BBF classifier cascade to detect objects in a given image. If you have several classifier cascades, it is better to use them in one method call. In this way, ccv will try to optimize the overall performance.
    1806
     * @param a The input image.
    1807
     * @param cascade An array of classifier cascades.
    1808
     * @param count How many classifier cascades you've passed in.
    1809
     * @param params A **ccv_bbf_param_t** structure that defines various aspects of the detector.
    1810
     * @return A **ccv_array_t** of **ccv_comp_t** for detection results.
    1811
     */
    1812
    CCV_WARN_UNUSED(ccv_array_t*) ccv_bbf_detect_objects(ccv_dense_matrix_t* a, ccv_bbf_classifier_cascade_t** cascade, int count, ccv_bbf_param_t params);
    1813
    /**
    1814
     * Read BBF classifier cascade from working directory.
    1815
     * @param directory The working directory that trains a BBF classifier cascade.
    1816
     * @return A classifier cascade, 0 if no valid classifier cascade available.
    1817
     */
    1818
    CCV_WARN_UNUSED(ccv_bbf_classifier_cascade_t*) ccv_bbf_read_classifier_cascade(const char* directory);
    1819
    /**
    1820
     * Free up the memory of BBF classifier cascade.
    1821
     * @param cascade The BBF classifier cascade.
    1822
     */
    1823
    void ccv_bbf_classifier_cascade_free(ccv_bbf_classifier_cascade_t* cascade);
    1824
    /**
    1825
     * Load BBF classifier cascade from a memory region.
    1826
     * @param s The memory region of binarized BBF classifier cascade.
    1827
     * @return A classifier cascade, 0 if no valid classifier cascade available.
    1828
     */
    1829
    CCV_WARN_UNUSED(ccv_bbf_classifier_cascade_t*) ccv_bbf_classifier_cascade_read_binary(char* s);
    1830
    /**
    1831
     * Write BBF classifier cascade to a memory region.
    1832
     * @param cascade The BBF classifier cascade.
    1833
     * @param s The designated memory region.
    1834
     * @param slen The size of the designated memory region.
    1835
     * @return The actual size of the binarized BBF classifier cascade, if this size is larger than **slen**, please reallocate the memory region and do it again.
    1836
     */
    1837
    int ccv_bbf_classifier_cascade_write_binary(ccv_bbf_classifier_cascade_t* cascade, char* s, int slen);
    1838
    /** @} */
    1839
    1840
    /* Ferns classifier: this is a fern implementation that specifically used for TLD
    1841
     * see: http://cvlab.epfl.ch/alumni/oezuysal/ferns.html for more about ferns */
    1842
    1843
    typedef struct {
    1844
      int structs;
    1845
      int features;
    1846
      int scales;
    1847
      int posteriors;
    1848
      float threshold;
    1849
      int cnum[2];
    1850
      int* rnum;
    1851
      float* posterior;
    1852
      // decided to go flat organized fern so that we can profiling different memory layout impacts the performance
    1853
      ccv_point_t fern[1];
    1854
    } ccv_ferns_t;
    1855
    1856
    CCV_WARN_UNUSED(ccv_ferns_t*) ccv_ferns_new(int structs, int features, int scales, ccv_size_t* sizes);
    1857
    void ccv_ferns_feature(ccv_ferns_t* ferns, ccv_dense_matrix_t* a, int scale, uint32_t* fern);
    1858
    void ccv_ferns_correct(ccv_ferns_t* ferns, uint32_t* fern, int c, int repeat);
    1859
    float ccv_ferns_predict(ccv_ferns_t* ferns, uint32_t* fern);
    1860
    void ccv_ferns_free(ccv_ferns_t* ferns);
    1861
    1862
    /* TLD: Track-Learn-Detection is a long-term object tracking framework, which achieved very high
    1863
     * tracking accuracy, this is the tracking algorithm of choice ccv implements */
    1864
    /**
    1865
     * @defgroup ccv_tld track learn detect
    1866
     * @{
    1867
     */
    1868
    1869
    typedef struct {
    1870
      /**
    1871
       * @name Short-term lucas-kanade tracking parameters
    1872
       * @{
    1873
       */
    1874
      ccv_size_t win_size; /**< The window size to compute optical flow. */
    1875
      int level; /**< Level of image pyramids */
    1876
      float min_eigen; /**< The minimal eigenvalue for a valid optical flow computation */
    1877
      float min_forward_backward_error; /**< The minimal forward backward error */
    1878
      /** @} */
    1879
      /**
    1880
       * @name Image pyramid generation parameters (for scale-invariant object detection)
    1881
       * @{
    1882
       */
    1883
      int interval; /**< How many intermediate images in between each image pyramid level (from width => width / 2) */
    1884
      float shift; /**< How much steps sliding window should move */
    1885
      /** @} */
    1886
      /**
    1887
       * @name Samples generation parameters
    1888
       * @{
    1889
       */
    1890
      int min_win; /**< The minimal window size of patches for detection */
    1891
      float include_overlap; /**< Above this threshold, a bounding box will be positively identified as overlapping with target */
    1892
      float exclude_overlap; /**< Below this threshold, a bounding box will be positively identified as not overlapping with target */
    1893
      /** @} */
    1894
      /**
    1895
       * @name Ferns classifier parameters
    1896
       * @{
    1897
       */
    1898
      int structs; /**< How many ferns in the classifier */
    1899
      int features; /**< How many features for each fern */
    1900
      /** @} */
    1901
      /**
    1902
       * @name Nearest neighbor classifier parameters
    1903
       * @{
    1904
       */
    1905
      float validate_set; /**< For the conservative confidence score will be only computed on a subset of all positive examples, this value gives how large that subset should be, 0.5 is a reasonable number */
    1906
      float nnc_same; /**< Above this threshold, a given patch will be identified as the same */
    1907
      float nnc_thres; /**< The initial threshold for positively recognize a patch */
    1908
      float nnc_verify; /**< The threshold for a tracking result from short-term tracker be verified as a positive detection */
    1909
      float nnc_beyond; /**< The upper bound threshold for adaptive computed threshold */
    1910
      float nnc_collect; /**< The threshold that a negative patch above this will be collected as negative example */
    1911
      int bad_patches; /**< How many patches should be evaluated in initialization to collect enough negative examples */
    1912
      /** @} */
    1913
      /**
    1914
       * @name Deformation parameters to apply perspective transforms on patches for robustness
    1915
       * @{
    1916
       */
    1917
      int new_deform; /**< Number of deformations should be applied at initialization */
    1918
      int track_deform; /**< Number of deformations should be applied at running time */
    1919
      float new_deform_angle; /**< The maximal angle for x, y and z axis rotation at initialization */
    1920
      float track_deform_angle; /**< The maximal angle for x, y and z axis rotation at running time */
    1921
      float new_deform_scale; /**< The maximal scale for the deformation at initialization */
    1922
      float track_deform_scale; /**< The maximal scale for the deformation at running time */
    1923
      float new_deform_shift; /**< The maximal shift for the deformation at initialization */
    1924
      float track_deform_shift; /**< The maximal shift for the deformation at running time */
    1925
      /** @} */
    1926
      /**
    1927
       * @name Speed up parameters
    1928
       * @{
    1929
       */
    1930
      int top_n; /**< Only keep these much positive detections when applying ferns classifier */
    1931
      /* speed up technique, instead of running slide window at
    1932
       * every frame, we will rotate them, for example, slide window 1
    1933
       * only gets examined at frame % rotation == 1 */
    1934
      int rotation; /**< When >= 1, using "rotation" technique, which, only evaluate a subset of sliding windows for each frame, but after rotation + 1 frames, every sliding window will be evaluated in one of these frames. */
    1935
      /** @} */
    1936
    } ccv_tld_param_t;
    1937
    1938
    extern const ccv_tld_param_t ccv_tld_default_params;
    1939
    1940
    typedef struct {
    1941
      ccv_tld_param_t params;
    1942
      ccv_comp_t box; // tracking comp
    1943
      ccv_ferns_t* ferns; // ferns classifier
    1944
      ccv_array_t* sv[2]; // example-based classifier
    1945
      ccv_size_t patch; // resized to patch for example-based classifier
    1946
      int found; // if the last time found a valid box
    1947
      int verified; // the last frame is verified, therefore, a successful tracking is verified too
    1948
      ccv_array_t* top; // top matches
    1949
      float ferns_thres; // computed dynamically from negative examples
    1950
      float nnc_thres; // computed dynamically from negative examples
    1951
      float nnc_verify_thres; // computed dynamically from negative examples
    1952
      double var_thres; // computed dynamically from the supplied same
    1953
      uint64_t frame_signature;
    1954
      int count;
    1955
      void* sfmt;
    1956
      void* dsfmt;
    1957
      uint32_t fern_buffer[1]; // fetched ferns from image, this is a buffer
    1958
    } ccv_tld_t;
    1959
    1960
    typedef struct {
    1961
      int perform_track; /**< Whether we performed tracking or not this time */
    1962
      int perform_learn; /**< Whether we performed learning or not this time */
    1963
      int track_success; /**< If we have a successful tracking (thus, short term tracker works) */
    1964
      int ferns_detects; /**< How many regions passed ferns classifier */
    1965
      int nnc_detects; /**< How many regions passed nearest neighbor classifier */
    1966
      int clustered_detects; /**< After cluster, how many regions left */
    1967
      int confident_matches; /**< How many matches we have outside of the tracking region (may cause a re-initialization of the short term tracking) */
    1968
      int close_matches; /**< How many matches we have inside the tracking (may cause a new learning event) */
    1969
    } ccv_tld_info_t;
    1970
    1971
    /**
    1972
     * Create a new TLD tracking instance from a given first frame image and the tracking rectangle.
    1973
     * @param a The first frame image.
    1974
     * @param box The initial tracking rectangle.
    1975
     * @param params A **ccv_tld_param_t** structure that defines various aspects of TLD tracker.
    1976
     * @return A **ccv_tld_t** object holds temporal information about tracking.
    1977
     */
    1978
    CCV_WARN_UNUSED(ccv_tld_t*) ccv_tld_new(ccv_dense_matrix_t* a, ccv_rect_t box, ccv_tld_param_t params);
    1979
    /**
    1980
     * ccv doesn't have retain / release semantics. Thus, a TLD instance cannot retain the most recent frame it tracks for future reference, you have to pass that in by yourself.
    1981
     * @param tld The TLD instance for continuous tracking
    1982
     * @param a The last frame used for tracking (ccv_tld_track_object will check signature of this against the last frame TLD instance tracked)
    1983
     * @param b The new frame will be tracked
    1984
     * @param info A **ccv_tld_info_t** structure that will records several aspects of current tracking
    1985
     * @return The newly predicted bounding box for the tracking object.
    1986
     */
    1987
    ccv_comp_t ccv_tld_track_object(ccv_tld_t* tld, ccv_dense_matrix_t* a, ccv_dense_matrix_t* b, ccv_tld_info_t* info);
    1988
    /**
    1989
     * @param tld The TLD instance to be freed.
    1990
     */
    1991
    void ccv_tld_free(ccv_tld_t* tld);
    1992
    /** @} */
    1993
    1994
    /* ICF: Integral Channels Features, this is a theorized framework that retrospectively incorporates the original
    1995
     * Viola-Jones detection method with various enhancement later. Specifically, this implementation is after:
    1996
     * Pedestrian detection at 100 frames per second, Rodrigo Benenson, Markus Mathias, Radu Timofte and Luc Van Gool
    1997
     * With WFS (width first search) tree from:
    1998
     * High-Performance Rotation Invariant Multiview Face Detection, Chang Huang, Haizhou Ai, Yuan Li and Shihong Lao */
    1999
    2000
    /**
    2001
     * @defgroup ccv_icf integral channel features
    2002
     * @{
    2003
     */
    2004
    2005
    #define CCV_ICF_SAT_MAX (2)
    2006
    2007
    typedef struct {
    2008
      int count;
    2009
      int channel[CCV_ICF_SAT_MAX];
    2010
      ccv_point_t sat[CCV_ICF_SAT_MAX * 2];
    2011
      float alpha[CCV_ICF_SAT_MAX];
    2012
      float beta;
    2013
    } ccv_icf_feature_t;
    2014
    2015
    typedef struct {
    2016
      // we use depth-2 decision tree
    2017
      uint32_t pass;
    2018
      ccv_icf_feature_t features[3];
    2019
      float weigh[2];
    2020
      float threshold;
    2021
    } ccv_icf_decision_tree_t;
    2022
    2023
    enum {
    2024
      CCV_ICF_CLASSIFIER_TYPE_A = 0x1,
    2025
      CCV_ICF_CLASSIFIER_TYPE_B = 0x2,
    2026
    };
    2027
    2028
    typedef struct {
    2029
      int type;
    2030
      int count;
    2031
      int grayscale;
    2032
      ccv_margin_t margin;
    2033
      ccv_size_t size; // this is the size includes the margin
    2034
      ccv_icf_decision_tree_t* weak_classifiers;
    2035
    } ccv_icf_classifier_cascade_t; // Type A, scale image
    2036
    2037
    typedef struct {
    2038
      int type;
    2039
      int count;
    2040
      int octave;
    2041
      int grayscale;
    2042
      ccv_icf_classifier_cascade_t* cascade;
    2043
    } ccv_icf_multiscale_classifier_cascade_t; // Type B, scale the classifier
    2044
    2045
    typedef struct {
    2046
      int min_neighbors; /**< 0: no grouping afterwards. 1: group objects that intersects each other. > 1: group objects that intersects each other, and only passes these that have at least **min_neighbors** intersected objects. */
    2047
      int flags;
    2048
      int step_through; /**< The step size for detection. */
    2049
      int interval; /**< Interval images between the full size image and the half size one. e.g. 2 will generate 2 images in between full size image and half size one: image with full size, image with 5/6 size, image with 2/3 size, image with 1/2 size. */
    2050
      float threshold;
    2051
    } ccv_icf_param_t;
    2052
    2053
    extern const ccv_icf_param_t ccv_icf_default_params;
    2054
    2055
    typedef struct {
    2056
      ccv_icf_param_t detector; /**< A **ccv_icf_param_t** structure that defines various aspects of the detector. */
    2057
      int grayscale; /**< Whether to exploit color in a given image. */
    2058
      int min_dimension; /**< The minimal size of a ICF feature region. */
    2059
      ccv_margin_t margin;
    2060
      ccv_size_t size; /**< A **ccv_size_t** structure that defines the width and height of the classifier. */
    2061
      int feature_size; /**< The number of ICF features to pool from. */
    2062
      int weak_classifier; /**< The number of weak classifiers that will be used to construct the strong classifier. */
    2063
      int bootstrap; /**< The number of boostrap to collect negatives. */
    2064
      float deform_angle; /**< The range of rotations to add distortion, in radius. */
    2065
      float deform_scale; /**< The range of scale changes to add distortion. */
    2066
      float deform_shift; /**< The range of translations to add distortion, in pixel. */
    2067
      double acceptance; /**< The percentage of validation examples will be accepted when soft cascading the classifiers that will be sued for bootstrap. */
    2068
    } ccv_icf_new_param_t;
    2069
    2070
    void ccv_icf(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type);
    2071
    2072
    /* ICF for single scale */
    2073
    /**
    2074
     * Create a new ICF classifier cascade from given positive examples and background images. This function has a hard dependency on [GSL](http://www.gnu.org/software/gsl/) and better be used with [libdispatch](http://libdispatch.macosforge.org/) for maximum efficiency.
    2075
     * @param posfiles An array of **ccv_file_info_t** that gives the positive examples and their locations.
    2076
     * @param posnum The number of positive examples that we want to use (with certain random distortions if so choose).
    2077
     * @param bgfiles An array of **ccv_file_info_t** that gives the background images.
    2078
     * @param negnum The number of negative examples will be collected during bootstrapping / initialization.
    2079
     * @param testfiles An array of **ccv_file_info_t** that gives the validation examples and their locations.
    2080
     * @param dir The directory that saves the progress.
    2081
     * @param params A **ccv_icf_new_param_t** structure that defines various aspects of the training function.
    2082
     * @return A trained classifier cascade.
    2083
     */
    2084
    CCV_WARN_UNUSED(ccv_icf_classifier_cascade_t*) ccv_icf_classifier_cascade_new(ccv_array_t* posfiles, int posnum, ccv_array_t* bgfiles, int negnum, ccv_array_t* testfiles, const char* dir, ccv_icf_new_param_t params);
    2085
    /**
    2086
     * Compute soft cascade thresholds to speed up the classifier cascade performance.
    2087
     * @param cascade The trained classifier that we want to optimize soft cascade thresholds on.
    2088
     * @param posfiles An array of **ccv_array_t** that gives the positive examples and their locations.
    2089
     * @param acceptance The percentage of positive examples will be accepted when optimizing the soft cascade thresholds.
    2090
     */
    2091
    void ccv_icf_classifier_cascade_soft(ccv_icf_classifier_cascade_t* cascade, ccv_array_t* posfiles, double acceptance);
    2092
    /**
    2093
     * Read a ICF classifier from a file.
    2094
     * @param filename The file path that contains the trained ICF classifier.
    2095
     * @return The classifier cascade, 0 if no valid classifier cascade available.
    2096
     */
    2097
    CCV_WARN_UNUSED(ccv_icf_classifier_cascade_t*) ccv_icf_read_classifier_cascade(const char* filename);
    2098
    /**
    2099
     * Write a ICF classifier to a file.
    2100
     * @param classifier The classifier that we want to write to file.
    2101
     * @param filename The file path that we want to persist the ICF classifier.
    2102
     */
    2103
    void ccv_icf_write_classifier_cascade(ccv_icf_classifier_cascade_t* classifier, const char* filename);
    2104
    /**
    2105
     * Free up the memory of ICF classifier cascade.
    2106
     * @param classifier The ICF classifier cascade.
    2107
     */
    2108
    void ccv_icf_classifier_cascade_free(ccv_icf_classifier_cascade_t* classifier);
    2109
    2110
    /* ICF for multiple scale */
    2111
    CCV_WARN_UNUSED(ccv_icf_multiscale_classifier_cascade_t*) ccv_icf_multiscale_classifier_cascade_new(ccv_icf_classifier_cascade_t* cascades, int octave, int interval);
    2112
    CCV_WARN_UNUSED(ccv_icf_multiscale_classifier_cascade_t*) ccv_icf_read_multiscale_classifier_cascade(const char* directory);
    2113
    void ccv_icf_write_multiscale_classifier_cascade(ccv_icf_multiscale_classifier_cascade_t* classifier, const char* directory);
    2114
    void ccv_icf_multiscale_classifier_cascade_free(ccv_icf_multiscale_classifier_cascade_t* classifier);
    2115
    2116
    /* polymorph function to run ICF based detector */
    2117
    /**
    2118
     * Using a ICF classifier cascade to detect objects in a given image. If you have several classifier cascades, it is better to use them in one method call. In this way, ccv will try to optimize the overall performance.
    2119
     * @param a The input image.
    2120
     * @param cascade An array of classifier cascades.
    2121
     * @param count How many classifier cascades you've passed in.
    2122
     * @param params A **ccv_icf_param_t** structure that defines various aspects of the detector.
    2123
     * @return A **ccv_array_t** of **ccv_comp_t** with detection results.
    2124
     */
    2125
    CCV_WARN_UNUSED(ccv_array_t*) ccv_icf_detect_objects(ccv_dense_matrix_t* a, void* cascade, int count, ccv_icf_param_t params);
    2126
    /** @} */
    2127
    2128
    /* SCD: SURF-Cascade Detector
    2129
     * This is a variant of VJ framework for object detection
    2130
     * Read: Learning SURF Cascade for Fast and Accurate Object Detection
    2131
     */
    2132
    /**
    2133
     * @defgroup ccv_scd surf-cascade detection
    2134
     * @{
    2135
     */
    2136
    2137
    typedef struct {
    2138
      int sx[4];
    2139
      int sy[4];
    2140
      int dx[4];
    2141
      int dy[4];
    2142
      float bias;
    2143
      float w[32];
    2144
    } ccv_scd_stump_feature_t;
    2145
    2146
    typedef struct {
    2147
      int count;
    2148
      ccv_scd_stump_feature_t* features;
    2149
      float threshold;
    2150
    } ccv_scd_stump_classifier_t;
    2151
    2152
    // this is simpler than ccv's icf feature, largely inspired
    2153
    // by the latest implementation of doppia, it seems more restrictive
    2154
    // approach can generate more robust feature due to the overfitting
    2155
    // nature of decision tree
    2156
    typedef struct {
    2157
      int channel;
    2158
      int sx;
    2159
      int sy;
    2160
      int dx;
    2161
      int dy;
    2162
      float bias;
    2163
    } ccv_scd_tree_feature_t;
    2164
    2165
    enum {
    2166
      CCV_SCD_STUMP_FEATURE = 0x01,
    2167
      CCV_SCD_TREE_FEATURE = 0x02,
    2168
    };
    2169
    2170
    typedef struct {
    2171
      int type;
    2172
      uint32_t pass;
    2173
      ccv_scd_stump_feature_t feature;
    2174
      ccv_scd_tree_feature_t node[3];
    2175
      float beta[6];
    2176
      float threshold;
    2177
    } ccv_scd_decision_tree_t;
    2178
    2179
    typedef struct {
    2180
      int count;
    2181
      ccv_margin_t margin;
    2182
      ccv_size_t size;
    2183
      ccv_scd_stump_classifier_t* classifiers;
    2184
      // the last stage classifier is a hybrid of scd feature with icf-like feature
    2185
      // this is trained as soft-cascade classifier, and select between a depth-2 decision tree
    2186
      // or the scd feature.
    2187
      struct {
    2188
        int count;
    2189
        ccv_scd_decision_tree_t* tree;
    2190
      } decision;
    2191
    } ccv_scd_classifier_cascade_t;
    2192
    2193
    typedef struct {
    2194
      int min_neighbors; /**< 0: no grouping afterwards. 1: group objects that intersects each other. > 1: group objects that intersects each other, and only passes these that have at least **min_neighbors** intersected objects. */
    2195
      int step_through; /**< The step size for detection. */
    2196
      int interval; /**< Interval images between the full size image and the half size one. e.g. 2 will generate 2 images in between full size image and half size one: image with full size, image with 5/6 size, image with 2/3 size, image with 1/2 size. */
    2197
      ccv_size_t size; /**< The smallest object size that will be interesting to us. */
    2198
    } ccv_scd_param_t;
    2199
    2200
    typedef struct {
    2201
      int boosting; /**< How many stages of boosting should be performed. */
    2202
      ccv_size_t size; /**< What's the window size of the final classifier. */
    2203
      struct {
    2204
        ccv_size_t base; /**< [feature.base] A **ccv_size_t** structure defines the minimal feature dimensions. */
    2205
        int range_through; /**< [feature.range_through] The step size to increase feature dimensions. */
    2206
        int step_through; /**< [feature.step_through] The step size to move to cover the whole window size. */
    2207
      } feature;
    2208
      struct {
    2209
        float hit_rate; /**< [stop_criteria.hit_rate] The targeted hit rate for each stage of classifier. */
    2210
        float false_positive_rate; /**< [stop_criteria.false_positive_rate] The targeted false positive rate for each stage of classifier. */
    2211
        float accu_false_positive_rate; /**< [stop_criteria.accu_false_positive_rate] The targeted accumulative false positive rate for classifier cascade, the training will be terminated once the accumulative false positive rate target reached. */
    2212
        float auc_crit; /**< [stop_criteria.auc_crit] The epsilon to decide if auc (area under curve) can no longer be improved. Once auc can no longer be improved and the targeted false positive rate reached, this stage of training will be terminated and start the next stage training. */
    2213
        int maximum_feature; /**< [stop_criteria.maximum_feature] Maximum number of features one stage can have. */
    2214
        int prune_stage; /**< [stop_criteria.prune_stage] How many stages will act as "prune" stage, which means will take minimal effort to prune as much negative areas as possible. */
    2215
        int prune_feature; /**< [stop_criteria.prune_feature] How many features a prune stage should have, it should be a very small number to enable efficient pruning. */
    2216
      } stop_criteria;
    2217
      double weight_trimming; /**< Only consider examples with weights in this percentile for training, this avoid to consider examples with tiny weights. */
    2218
      double C; /**< The C parameter to train the weak linear SVM classifier. */
    2219
      int grayscale; /**< To train the classifier with grayscale image. */
    2220
    } ccv_scd_train_param_t;
    2221
    2222
    extern const ccv_scd_param_t ccv_scd_default_params;
    2223
    2224
    /**
    2225
     * Create a new SCD classifier cascade from given positive examples and background images. This function has a hard dependency on [GSL](http://www.gnu.org/software/gsl/).
    2226
     * @param posfiles An array of **ccv_file_info_t** that gives the positive examples.
    2227
     * @param hard_mine An array of **ccv_file_info_t** that gives images don't contain any positive examples (for example, to train a face detector, these are images that doesn't contain any faces).
    2228
     * @param negative_count Number of negative examples that is harvested from background images.
    2229
     * @param filename The file that saves both progress and final classifier, this will be in sqlite3 database format.
    2230
     * @param params A **ccv_scd_train_param_t** that defines various aspects of the training function.
    2231
     * @return The trained SCD classifier cascade.
    2232
     */
    2233
    CCV_WARN_UNUSED(ccv_scd_classifier_cascade_t*) ccv_scd_classifier_cascade_new(ccv_array_t* posfiles, ccv_array_t* hard_mine, int negative_count, const char* filename, ccv_scd_train_param_t params);
    2234
    /**
    2235
     * Write SCD classifier cascade to a file.
    2236
     * @param cascade The BBF classifier cascade.
    2237
     * @param filename The file that will be written to, it is in sqlite3 database format.
    2238
     */
    2239
    void ccv_scd_classifier_cascade_write(ccv_scd_classifier_cascade_t* cascade, const char* filename);
    2240
    /**
    2241
     * Read SCD classifier cascade from file.
    2242
     * @param filename The file that contains a SCD classifier cascade, it is in sqlite3 database format.
    2243
     * @return A classifier cascade, 0 returned if no valid classifier cascade available.
    2244
     */
    2245
    CCV_WARN_UNUSED(ccv_scd_classifier_cascade_t*) ccv_scd_classifier_cascade_read(const char* filename);
    2246
    /**
    2247
     * Free up the memory of SCD classifier cascade.
    2248
     * @param cascade The SCD classifier cascade.
    2249
     */
    2250
    void ccv_scd_classifier_cascade_free(ccv_scd_classifier_cascade_t* cascade);
    2251
    2252
    /**
    2253
     * Generate 8-channel output matrix which extract SURF features (dx, dy, |dx|, |dy|, du, dv, |du|, |dv|) for input. If input is multi-channel matrix (such as RGB), will pick the strongest responses among these channels.
    2254
     * @param a The input matrix.
    2255
     * @param b The output matrix.
    2256
     * @param type The type of output matrix, if 0, ccv will try to match the input matrix for appropriate type.
    2257
     */
    2258
    void ccv_scd(ccv_dense_matrix_t* a, ccv_dense_matrix_t** b, int type);
    2259
    /**
    2260
     * Using a SCD classifier cascade to detect objects in a given image. If you have several classifier cascades, it is better to use them in one method call. In this way, ccv will try to optimize the overall performance.
    2261
     * @param a The input image.
    2262
     * @param cascades An array of classifier cascades.
    2263
     * @param count How many classifier cascades you've passed in.
    2264
     * @param params A **ccv_scd_param_t** structure that defines various aspects of the detector.
    2265
     * @return A **ccv_array_t** of **ccv_comp_t** with detection results.
    2266
     */
    2267
    CCV_WARN_UNUSED(ccv_array_t*) ccv_scd_detect_objects(ccv_dense_matrix_t* a, ccv_scd_classifier_cascade_t** cascades, int count, ccv_scd_param_t params);
    2268
    /** @} */
    2269
    2270
    /* categorization types and methods for training */
    2271
    2272
    enum {
    2273
      CCV_CATEGORIZED_DENSE_MATRIX = 0x01,
    2274
      CCV_CATEGORIZED_FILE = 0x02,
    2275
    };
    2276
    2277
    typedef struct {
    2278
      int c; // class / category label
    2279
      int type;
    2280
      union {
    2281
        ccv_dense_matrix_t* matrix;
    2282
        ccv_file_info_t file;
    2283
      };
    2284
    } ccv_categorized_t;
    2285
    2286
    inline static ccv_categorized_t ccv_categorized(int c, ccv_dense_matrix_t* matrix, ccv_file_info_t* file)
    2287
    180k
    {
    2288
    180k
      assert((matrix && !file) || (!matrix && file));
    2289
    180k
      ccv_categorized_t categorized;
    2290
    180k
      categorized.c = c;
    2291
    180k
      if (matrix)
    2292
    180k
        categorized.type = CCV_CATEGORIZED_DENSE_MATRIX, categorized.matrix = matrix;
    2293
    0
      else
    2294
    0
        categorized.type = CCV_CATEGORIZED_FILE, categorized.file = *file;
    2295
    180k
      return categorized;
    2296
    180k
    }
    Unexecuted instantiation: adam.tests.c:ccv_categorized

    cifar.tests.c:ccv_categorized

    Line
    Count
    Source
    2287
    180k
    {
    2288
    180k
      assert((matrix && !file) || (!matrix && file));
    2289
    180k
      ccv_categorized_t categorized;
    2290
    180k
      categorized.c = c;
    2291
    180k
      if (matrix)
    2292
    180k
        categorized.type = CCV_CATEGORIZED_DENSE_MATRIX, categorized.matrix = matrix;
    2293
    0
      else
    2294
    0
        categorized.type = CCV_CATEGORIZED_FILE, categorized.file = *file;
    2295
    180k
      return categorized;
    2296
    180k
    }
    Unexecuted instantiation: cnnp.core.tests.c:ccv_categorized
    Unexecuted instantiation: compare.tests.c:ccv_categorized
    Unexecuted instantiation: compression.tests.c:ccv_categorized
    Unexecuted instantiation: concat.tests.c:ccv_categorized
    Unexecuted instantiation: cublas.tests.c:ccv_categorized
    Unexecuted instantiation: cudnn.tests.c:ccv_categorized
    Unexecuted instantiation: datatype.tests.c:ccv_categorized
    Unexecuted instantiation: dense.net.tests.c:ccv_categorized
    Unexecuted instantiation: dynamic.graph.tests.c:ccv_categorized
    Unexecuted instantiation: gelu.tests.c:ccv_categorized
    Unexecuted instantiation: graph.vgg.d.tests.c:ccv_categorized
    Unexecuted instantiation: imdb.tests.c:ccv_categorized
    Unexecuted instantiation: index.tests.c:ccv_categorized
    Unexecuted instantiation: lamb.tests.c:ccv_categorized
    Unexecuted instantiation: leaky_relu.tests.c:ccv_categorized
    Unexecuted instantiation: loss.tests.c:ccv_categorized
    Unexecuted instantiation: lstm.tests.c:ccv_categorized
    Unexecuted instantiation: mpsblas.tests.c:ccv_categorized
    Unexecuted instantiation: mpsdnn.tests.c:ccv_categorized
    Unexecuted instantiation: nccl.tests.c:ccv_categorized
    Unexecuted instantiation: nms.tests.c:ccv_categorized
    Unexecuted instantiation: pad.tests.c:ccv_categorized
    Unexecuted instantiation: palettize.tests.c:ccv_categorized
    Unexecuted instantiation: parallel.tests.c:ccv_categorized
    Unexecuted instantiation: partition.tests.c:ccv_categorized
    Unexecuted instantiation: random.tests.c:ccv_categorized
    Unexecuted instantiation: reduce.tests.c:ccv_categorized
    Unexecuted instantiation: rmsprop.tests.c:ccv_categorized
    Unexecuted instantiation: roi_align.tests.c:ccv_categorized
    Unexecuted instantiation: scatter_add.tests.c:ccv_categorized
    Unexecuted instantiation: schedule.tests.c:ccv_categorized
    Unexecuted instantiation: sgd.tests.c:ccv_categorized
    Unexecuted instantiation: smooth_l1.tests.c:ccv_categorized
    Unexecuted instantiation: sort.tests.c:ccv_categorized
    Unexecuted instantiation: swish.tests.c:ccv_categorized
    Unexecuted instantiation: symbolic.graph.vgg.d.tests.c:ccv_categorized
    Unexecuted instantiation: tensor.tests.c:ccv_categorized
    Unexecuted instantiation: transform.tests.c:ccv_categorized
    Unexecuted instantiation: unique_consecutive.tests.c:ccv_categorized
    Unexecuted instantiation: upsample.tests.c:ccv_categorized
    Unexecuted instantiation: defects.l0.1.tests.c:ccv_categorized
    Unexecuted instantiation: 3rdparty.tests.c:ccv_categorized
    Unexecuted instantiation: algebra.tests.c:ccv_categorized
    Unexecuted instantiation: basic.tests.c:ccv_categorized
    Unexecuted instantiation: convnet.tests.c:ccv_categorized
    Unexecuted instantiation: image_processing.tests.c:ccv_categorized
    Unexecuted instantiation: io.tests.c:ccv_categorized
    Unexecuted instantiation: memory.tests.c:ccv_categorized
    Unexecuted instantiation: attention.tests.c:ccv_categorized
    Unexecuted instantiation: autograd.tests.c:ccv_categorized
    Unexecuted instantiation: autograd.vector.tests.c:ccv_categorized
    Unexecuted instantiation: backward.tests.c:ccv_categorized
    Unexecuted instantiation: batch.norm.tests.c:ccv_categorized
    Unexecuted instantiation: broadcast.tests.c:ccv_categorized
    Unexecuted instantiation: case_of.backward.tests.c:ccv_categorized
    Unexecuted instantiation: case_of.tests.c:ccv_categorized
    Unexecuted instantiation: cblas.tests.c:ccv_categorized
    Unexecuted instantiation: complex.tests.c:ccv_categorized
    Unexecuted instantiation: crossentropy.tests.c:ccv_categorized
    Unexecuted instantiation: custom.tests.c:ccv_categorized
    Unexecuted instantiation: dataframe.addons.tests.c:ccv_categorized
    Unexecuted instantiation: dataframe.tests.c:ccv_categorized
    Unexecuted instantiation: dropout.tests.c:ccv_categorized
    Unexecuted instantiation: forward.tests.c:ccv_categorized
    Unexecuted instantiation: gemm.tests.c:ccv_categorized
    Unexecuted instantiation: gradient.tests.c:ccv_categorized
    Unexecuted instantiation: graph.io.tests.c:ccv_categorized
    Unexecuted instantiation: graph.tests.c:ccv_categorized
    Unexecuted instantiation: group.norm.tests.c:ccv_categorized
    Unexecuted instantiation: histogram.tests.c:ccv_categorized
    Unexecuted instantiation: layer.norm.tests.c:ccv_categorized
    Unexecuted instantiation: micro.tests.c:ccv_categorized
    Unexecuted instantiation: minimize.tests.c:ccv_categorized
    Unexecuted instantiation: numa.tests.c:ccv_categorized
    Unexecuted instantiation: rand.tests.c:ccv_categorized
    Unexecuted instantiation: rmsnorm.tests.c:ccv_categorized
    Unexecuted instantiation: simplify.tests.c:ccv_categorized
    Unexecuted instantiation: symbolic.graph.compile.tests.c:ccv_categorized
    Unexecuted instantiation: symbolic.graph.tests.c:ccv_categorized
    Unexecuted instantiation: tape.tests.c:ccv_categorized
    Unexecuted instantiation: tensor.bind.tests.c:ccv_categorized
    Unexecuted instantiation: tfb.tests.c:ccv_categorized
    Unexecuted instantiation: while.backward.tests.c:ccv_categorized
    Unexecuted instantiation: while.tests.c:ccv_categorized
    Unexecuted instantiation: winograd.tests.c:ccv_categorized
    Unexecuted instantiation: numeric.tests.c:ccv_categorized
    Unexecuted instantiation: output.tests.c:ccv_categorized
    Unexecuted instantiation: util.tests.c:ccv_categorized
    Unexecuted instantiation: ccv_cache.c:ccv_categorized
    Unexecuted instantiation: ccv_memory.c:ccv_categorized
    Unexecuted instantiation: ccv_io.c:ccv_categorized
    Unexecuted instantiation: ccv_numeric.c:ccv_categorized
    Unexecuted instantiation: ccv_algebra.c:ccv_categorized
    Unexecuted instantiation: ccv_util.c:ccv_categorized
    Unexecuted instantiation: ccv_basic.c:ccv_categorized
    Unexecuted instantiation: ccv_image_processing.c:ccv_categorized
    Unexecuted instantiation: ccv_resample.c:ccv_categorized
    Unexecuted instantiation: ccv_transform.c:ccv_categorized
    Unexecuted instantiation: ccv_classic.c:ccv_categorized
    Unexecuted instantiation: ccv_convnet.c:ccv_categorized
    Unexecuted instantiation: ccv_output.c:ccv_categorized
    Unexecuted instantiation: cwc_convnet_ext.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_cmd.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_tensor.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_tensor_io.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_stream.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_micro.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_micro_core.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_micro_interpret.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_micro_simplify.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_graph.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_io.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_compile.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_backward.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_while.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_graph_while.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_tensor_tape.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_case_of.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_graph_case_of.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_minimize.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_parallel.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_simplify.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_compression.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_memory_reduction.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_graph_run.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_xpu_alloc.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph_alloc.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph_backward.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph_apply_gradients.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph_minimize.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dynamic_graph_evaluate.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_dataframe.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_dataframe_core.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_dataframe_addons.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_dataframe_csv.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_model.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_model_io.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_model_core.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_model_addons.c:ccv_categorized
    Unexecuted instantiation: co.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_palettize.c:ccv_categorized
    Unexecuted instantiation: ccv_cnnp_model_gradient_checkpointing.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_symbolic_graph_chain_decomposition.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_adam_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_adamw_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_gemm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_gemm_cpu_opt.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_add_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_mul_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_cmul_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_segmented_gemm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_min_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_max_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_lssc_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_conv_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_conv_cpu_opt.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_conv_transpose_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dropout_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_ew_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_gelu_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_grid_sample_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_histogram_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_index_select_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_isnan_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_lamb_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_leaky_relu_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_binary_crossentropy_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_mse_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_smooth_l1_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_nms_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_batch_norm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_layer_norm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_group_norm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rmsnorm_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_pad_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_partition_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_max_pool_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_avg_pool_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rand_uniform_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rand_normal_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_sum_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_mean_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_max_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_min_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_norm2_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_argmax_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_argmin_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_relu_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rmsprop_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_roi_align_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_scatter_add_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sgd_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sigmoid_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_softmax_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sort_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_swish_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_tanh_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_unique_consecutive_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_upsample_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_util_cpu_ref.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_adam.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_blas.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_opt.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_gemm_cpu_sys.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_comm.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_cmp.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_compression.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_conv_cpu_4x4_3x3_winograd.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_conv_cpu_fft.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_conv_cpu_gemm.c:ccv_categorized
    Unexecuted instantiation: _ccv_nnc_conv_cpu_opt.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_convolution.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_dropout.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_ew.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_gelu.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_grid_sample.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_histogram.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_index_select.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce_isnan.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_lamb.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_leaky_relu.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_binary_crossentropy.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_categorical_crossentropy.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_mse.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_smooth_l1.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_nms.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_norm.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_pad.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_partition.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_pool.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rand.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_reduce.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_relu.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_rmsprop.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_lstm.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_roi_align.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_scaled_dot_product_attention.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_scatter_add.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sgd.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sigmoid.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sigmoid_binary_crossentropy.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_softmax.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_softmax_crossentropy.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_sort.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_swish.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_tanh.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_unique_consecutive.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_upsample.c:ccv_categorized
    Unexecuted instantiation: ccv_nnc_util.c:ccv_categorized
    2297
    2298
    /**
    2299
     * @defgroup ccv_convnet deep convolutional networks
    2300
     * This is a implementation of deep convolutional networks mainly for image recognition and object detection.
    2301
     * @{
    2302
     */
    2303
    2304
    enum {
    2305
      CCV_CONVNET_CONVOLUTIONAL = 0x01,
    2306
      CCV_CONVNET_FULL_CONNECT = 0x02,
    2307
      CCV_CONVNET_MAX_POOL = 0x03,
    2308
      CCV_CONVNET_AVERAGE_POOL = 0x04,
    2309
      CCV_CONVNET_LOCAL_RESPONSE_NORM = 0x05,
    2310
    };
    2311
    2312
    typedef union {
    2313
      struct {
    2314
        int count; /**< [convolutional.count] The number of filters for convolutional layer. */
    2315
        int strides; /**< [convolutional.strides] The strides for convolutional filter. */
    2316
        int border; /**< [convolutional.border] The padding border size for the input matrix. */
    2317
        int rows; /**< [convolutional.rows] The number of rows for convolutional filter. */
    2318
        int cols; /**< [convolutional.cols] The number of columns for convolutional filter. */
    2319
        int channels; /**< [convolutional.channels] The number of channels for convolutional filter. */
    2320
        int partition; /**< [convolutional.partition] The number of partitions for convolutional filter. */
    2321
      } convolutional;
    2322
      struct {
    2323
        int strides; /**< [pool.strides] The strides for pooling layer. */
    2324
        int size; /**< [pool.size] The window size for pooling layer. */
    2325
        int border; /**< [pool.border] The padding border size for the input matrix. */
    2326
      } pool;
    2327
      struct {
    2328
        int size; /**< [rnorm.size] The size of local response normalization layer. */
    2329
        float kappa; /**< [rnorm.kappa] As of b[i] = a[i] / (rnorm.kappa + rnorm.alpha * sum(a, i - rnorm.size / 2, i + rnorm.size / 2)) ^ rnorm.beta */
    2330
        float alpha; /**< [rnorm.alpha] See **rnorm.kappa**. */
    2331
        float beta; /**< [rnorm.beta] See **rnorm.kappa**. */
    2332
      } rnorm;
    2333
      struct {
    2334
        int relu; /**< [full_connect.relu] 0 - ReLU, 1 - no ReLU */
    2335
        int count; /**< [full_connect.count] The number of output nodes for full connect layer. */
    2336
      } full_connect;
    2337
    } ccv_convnet_type_t;
    2338
    2339
    typedef struct {
    2340
      struct {
    2341
        int rows; /**< [matrix.rows] The number of rows of the input matrix. */
    2342
        int cols; /**< [matrix.cols] The number of columns of the input matrix. */
    2343
        int channels; /**< [matrix.channels] The number of channels of the input matrix. */
    2344
        int partition; /**< [matrix.partition] The number of partitions of the input matrix, it must be dividable by the number of channels (it is partitioned by channels). */
    2345
      } matrix;
    2346
      struct {
    2347
        int count; /**< [node.count] The number of nodes. You should either use **node** or **matrix** to specify the input structure. */
    2348
      } node;
    2349
    } ccv_convnet_input_t;
    2350
    2351
    typedef struct {
    2352
      int type; /**< One of following value to specify the network layer type, **CCV_CONVNET_CONVOLUTIONAL**, **CCV_CONVNET_FULL_CONNECT**, **CCV_CONVNET_MAX_POOL**, **CCV_CONVNET_AVERAGE_POOL**, **CCV_CONVNET_LOCAL_RESPONSE_NORM**. */
    2353
      float bias; /**< The initialization value for bias if applicable (for convolutional layer and full connect layer). */
    2354
      float glorot; /**< The truncated uniform distribution coefficients for weights if applicable (for convolutional layer and full connect layer, glorot / sqrt(in + out)). */
    2355
      ccv_convnet_input_t input; /**< A **ccv_convnet_input_t** specifies the input structure. */
    2356
      ccv_convnet_type_t output; /**< A **ccv_convnet_type_t** specifies the output parameters and structure. */
    2357
    } ccv_convnet_layer_param_t;
    2358
    2359
    typedef struct {
    2360
      int type;
    2361
      float* w; // weight
    2362
      float* bias; // bias
    2363
      size_t wnum; // the number of weights
    2364
      ccv_convnet_input_t input; // the input requirement
    2365
      ccv_convnet_type_t net; // network configuration
    2366
      void* reserved;
    2367
    } ccv_convnet_layer_t;
    2368
    2369
    typedef struct {
    2370
      int use_cwc_accel; // use "ccv with cuda" acceleration
    2371
      // this is redundant, but good to enforcing what the input should look like
    2372
      ccv_size_t input;
    2373
      int rows;
    2374
      int cols;
    2375
      int channels;
    2376
      // count and layer of the convnet
    2377
      int count;
    2378
      ccv_dense_matrix_t* mean_activity; // mean activity to subtract from
    2379
      ccv_convnet_layer_t* layers; // the layer configuration
    2380
      // these can be reused and we don't need to reallocate memory
    2381
      ccv_dense_matrix_t** denoms; // denominators
    2382
      ccv_dense_matrix_t** acts; // hidden layers and output layers
    2383
      void* reserved;
    2384
    } ccv_convnet_t;
    2385
    2386
    typedef struct {
    2387
      float decay; /**< See **learn_rate**. */
    2388
      float learn_rate; /**< New velocity = **momentum** * old velocity - **decay** * **learn_rate** * old value + **learn_rate** * delta, new value = old value + new velocity */
    2389
      float momentum; /**< See **learn_rate**. */
    2390
    } ccv_convnet_layer_sgd_param_t;
    2391
    2392
    typedef struct {
    2393
      // the dropout rate, I find that dor is better looking than dropout_rate,
    2394
      // and drop out is happened on the input neuron (so that when the network
    2395
      // is used in real-world, I simply need to multiply its weights to 1 - dor
    2396
      // to get the real one)
    2397
      float dor; /**< The dropout rate for this layer, it is only applicable for full connect layer. */
    2398
      ccv_convnet_layer_sgd_param_t w; /**< A **ccv_convnet_layer_sgd_param_t** specifies the stochastic gradient descent update rule for weight, it is only applicable for full connect layer and convolutional layer. */
    2399
      ccv_convnet_layer_sgd_param_t bias; /**< A **ccv_convnet_layer_sgd_param_t** specifies the stochastic gradient descent update rule for bias, it is only applicable for full connect layer and convolutional layer weight. */
    2400
    } ccv_convnet_layer_train_param_t;
    2401
    2402
    typedef struct {
    2403
      int max_epoch; /**< The number of epoch (an epoch sweeps through all the examples) to go through before end the training. */
    2404
      int mini_batch; /**< The number of examples for a batch in stochastic gradient descent. */
    2405
      int iterations; /**< The number of iterations (an iteration is for one batch) before save the progress. */
    2406
      int sgd_frequency; /**< After how many batches when we do a SGD update. */
    2407
      int symmetric; /**< Whether to exploit the symmetric property of the provided examples. */
    2408
      int device_count; /**< Use how many GPU devices, this is capped by available CUDA devices on your system. For now, ccv's implementation only support up to 4 GPUs */
    2409
      int peer_access; /**< Enable peer access for cross device communications or not, this will enable faster multiple device training. */
    2410
      float image_manipulation; /**< The value for image brightness / contrast / saturation manipulations. */
    2411
      float color_gain; /**< The color variance for data augmentation (0 means no such augmentation). */
    2412
      struct {
    2413
        int min_dim; /**< [input.min_dim] The minimum dimensions for random resize of training images. */
    2414
        int max_dim; /**< [input.max_dim] The maximum dimensions for random resize of training images. */
    2415
      } input;
    2416
      ccv_convnet_layer_train_param_t* layer_params; /**< An C-array of **ccv_convnet_layer_train_param_t** training parameters for each layer. */
    2417
    } ccv_convnet_train_param_t;
    2418
    2419
    typedef struct {
    2420
      int half_precision; /**< Use half precision float point to represent network parameters. */
    2421
    } ccv_convnet_write_param_t;
    2422
    2423
    /**
    2424
     * Create a new (deep) convolutional network with specified parameters. ccv only supports convolutional layer (shared weights), max pooling layer, average pooling layer, full connect layer and local response normalization layer.
    2425
     * @param use_cwc_accel Whether use CUDA-enabled GPU to accelerate various computations for convolutional network.
    2426
     * @param input Ihe input size of the image, it is not necessarily the input size of the first convolutional layer.
    2427
     * @param params[] The C-array of **ccv_convnet_layer_param_t** that specifies the parameters for each layer.
    2428
     * @param count The size of params[] C-array.
    2429
     * @return A new deep convolutional network structs
    2430
     */
    2431
    CCV_WARN_UNUSED(ccv_convnet_t*) ccv_convnet_new(int use_cwc_accel, ccv_size_t input, ccv_convnet_layer_param_t params[], int count);
    2432
    /**
    2433
     * Verify the specified parameters make sense as a deep convolutional network.
    2434
     * @param convnet A deep convolutional network to verify.
    2435
     * @param output The output number of nodes (for the last full connect layer).
    2436
     * @return 0 if the given deep convolutional network making sense.
    2437
     */
    2438
    int ccv_convnet_verify(ccv_convnet_t* convnet, int output);
    2439
    /**
    2440
     * Start to train a deep convolutional network with given parameters and data.
    2441
     * @param convnet A deep convolutional network that is initialized.
    2442
     * @param categorizeds An array of images with its category information for training.
    2443
     * @param tests An array of images with its category information for validating.
    2444
     * @param filename The working file to save progress and the trained convolutional network.
    2445
     * @param params A ccv_convnet_train_param_t that specifies the training parameters.
    2446
     */
    2447
    void ccv_convnet_supervised_train(ccv_convnet_t* convnet, ccv_array_t* categorizeds, ccv_array_t* tests, const char* filename, ccv_convnet_train_param_t params);
    2448
    /**
    2449
     * Use a convolutional network to encode an image into a compact representation.
    2450
     * @param convnet The given convolutional network.
    2451
     * @param a A C-array of input images.
    2452
     * @param b A C-array of output matrix of compact representation.
    2453
     * @param batch The number of input images.
    2454
     */
    2455
    void ccv_convnet_encode(ccv_convnet_t* convnet, ccv_dense_matrix_t** a, ccv_dense_matrix_t** b, int batch);
    2456
    void ccv_convnet_input_formation(ccv_size_t input, ccv_dense_matrix_t* a, ccv_dense_matrix_t** b);
    2457
    /**
    2458
     * Use a convolutional network to classify an image into categories.
    2459
     * @param convnet The given convolutional network.
    2460
     * @param a A C-array of input images.
    2461
     * @param symmetric Whether the input is symmetric.
    2462
     * @param ranks A C-array of **ccv_array_t** contains top categories by the convolutional network.
    2463
     * @param tops The number of top categories return for each image.
    2464
     * @param batch The number of input images.
    2465
     */
    2466
    void ccv_convnet_classify(ccv_convnet_t* convnet, ccv_dense_matrix_t** a, int symmetric, ccv_array_t** ranks, int tops, int batch);
    2467
    /**
    2468
     * Read a convolutional network that persisted on the disk.
    2469
     * @param use_cwc_accel Use CUDA-enabled GPU acceleration.
    2470
     * @param filename The file on the disk.
    2471
     */
    2472
    CCV_WARN_UNUSED(ccv_convnet_t*) ccv_convnet_read(int use_cwc_accel, const char* filename);
    2473
    /**
    2474
     * Write a convolutional network to a disk.
    2475
     * @param convnet A given convolutional network.
    2476
     * @param filename The file on the disk.
    2477
     * @param params A **ccv_convnet_write_param_t** to specify the write parameters.
    2478
     */
    2479
    void ccv_convnet_write(ccv_convnet_t* convnet, const char* filename, ccv_convnet_write_param_t params);
    2480
    /**
    2481
     * Free up temporary resources of a given convolutional network.
    2482
     * @param convnet A convolutional network.
    2483
     */
    2484
    void ccv_convnet_compact(ccv_convnet_t* convnet);
    2485
    /**
    2486
     * Free up the memory of a given convolutional network.
    2487
     * @param convnet A convolutional network.
    2488
     */
    2489
    void ccv_convnet_free(ccv_convnet_t* convnet);
    2490
    /** @} */
    2491
    2492
    /* add for command-line outputs, b/c ccv's training steps has a ton of outputs,
    2493
     * and in the future, it can be piped into callback functions for critical information
    2494
     * (such as the on-going missing rate, or iterations etc.) */
    2495
    2496
    enum {
    2497
      CCV_CLI_ERROR = 1 << 2,
    2498
      CCV_CLI_INFO = 1 << 1,
    2499
      CCV_CLI_VERBOSE = 1,
    2500
      CCV_CLI_NONE = 0,
    2501
    };
    2502
    2503
    int ccv_cli_output_level_and_above(int level);
    2504
    void ccv_cli_set_output_levels(int level);
    2505
    int ccv_cli_get_output_levels(void);
    2506
    2507
    #define CCV_CLI_SET_OUTPUT_LEVEL_AND_ABOVE(level) ccv_cli_set_output_levels(ccv_cli_output_level_and_above(level))
    2508
    4.73M
    #define CCV_CLI_OUTPUT_LEVEL_IS(a) (a & ccv_cli_get_output_levels())
    2509
    2510
    #endif