[GRASS-QA] GRASS QA: soeren | ./grass6/lib/gpde/N_gradient.c |13 clones ( N_arrays.c N_gradient.c )| 1 monsters | 1 warnings

grass-qa at proxy.soccerlab.polymtl.ca grass-qa at proxy.soccerlab.polymtl.ca
Fri Apr 6 13:29:51 EDT 2007



Hello soeren,

here a report on your recent GRASS-CVS change:

ANALYSIS

your changes to files/functions:


lib/gpde/N_gradient.c functions


N_alloc_gradient_2d (Begins at: 30 Ends at: 46)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      17 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_2d (Begins at: 48 Ends at: 68)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      21 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_2d (Begins at: 70 Ends at: 95)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       4 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      26 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_2d (Begins at: 97 Ends at: 128)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      32 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_get_gradient_2d (Begins at: 130 Ends at: 167)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       4 |       |      OK |
CalledNBR:    |       6 |       |      OK |
LOC:          |      38 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_3d (Begins at: 169 Ends at: 185)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      17 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_3d (Begins at: 187 Ends at: 209)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      23 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_3d (Begins at: 211 Ends at: 239)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       6 |     * |         |
CalledNBR:    |       2 |       |      OK |
LOC:          |      29 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_3d (Begins at: 241 Ends at: 276)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      36 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_get_gradient_3d (Begins at: 278 Ends at: 321)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       5 |     * |         |
CalledNBR:    |       8 |       |      OK |
LOC:          |      44 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_neighbours_x (Begins at: 323 Ends at: 341)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      19 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_neighbours_x (Begins at: 343 Ends at: 366)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      24 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_neighbours_x (Begins at: 368 Ends at: 398)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       6 |     * |         |
CalledNBR:    |       2 |       |      OK |
LOC:          |      31 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_neighbours_x (Begins at: 401 Ends at: 428)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      28 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_neighbours_y (Begins at: 430 Ends at: 448)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      19 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_neighbours_y (Begins at: 450 Ends at: 472)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      23 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_neighbours_y (Begins at: 474 Ends at: 504)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       6 |     * |         |
CalledNBR:    |       2 |       |      OK |
LOC:          |      31 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_neighbours_y (Begins at: 507 Ends at: 534)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      28 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_neighbours_z (Begins at: 536 Ends at: 554)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      19 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_neighbours_z (Begins at: 556 Ends at: 581)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      26 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_neighbours_z (Begins at: 583 Ends at: 618)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       9 |   *** | MONSTER |
CalledNBR:    |       2 |       |      OK |
LOC:          |      36 |       |      OK |
--------------+---------+-------+---------+
1 metric are OUT OF RANGE!

N_copy_gradient_neighbours_z (Begins at: 621 Ends at: 652)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      32 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_neighbours_2d (Begins at: 654 Ends at: 676)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      23 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_neighbours_2d (Begins at: 678 Ends at: 700)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      23 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_neighbours_2d (Begins at: 703 Ends at: 736)
--------------+---------+-------+---------+
Complexity:   |       4 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       5 |       |      OK |
LOC:          |      34 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_neighbours_2d (Begins at: 739 Ends at: 772)
--------------+---------+-------+---------+
Complexity:   |       5 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      34 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_neighbours_3d (Begins at: 774 Ends at: 801)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       0 |       |      OK |
CalledNBR:    |       9 |       |      OK |
LOC:          |      28 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_neighbours_3d (Begins at: 803 Ends at: 832)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       9 |       |      OK |
LOC:          |      30 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_create_gradient_neighbours_3d (Begins at: 835 Ends at: 884)
--------------+---------+-------+---------+
Complexity:   |      10 |       |      OK |
ParamNBR:     |       8 |    ** | Warning |
CalledNBR:    |      10 |       |      OK |
LOC:          |      50 |       |      OK |
--------------+---------+-------+---------+
at least 1 values are close to an outlier please consider revising code

N_copy_gradient_neighbours_3d (Begins at: 887 Ends at: 933)
--------------+---------+-------+---------+
Complexity:   |      11 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       9 |       |      OK |
LOC:          |      47 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_field_2d (Begins at: 935 Ends at: 961)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       4 |       |      OK |
LOC:          |      27 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_field_2d (Begins at: 963 Ends at: 985)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      23 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_field_2d (Begins at: 988 Ends at: 1049)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      62 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_compute_gradient_field_2d (Begins at: 1051 Ends at: 1180)
--------------+---------+-------+---------+
Complexity:   |      10 |       |      OK |
ParamNBR:     |       5 |     * |         |
CalledNBR:    |      26 |       |      OK |
LOC:          |     130 |     * |         |
--------------+---------+-------+---------+
metrics are OK

N_compute_gradient_field_components_2d (Begins at: 1183 Ends at: 1234)
--------------+---------+-------+---------+
Complexity:   |       5 |       |      OK |
ParamNBR:     |       3 |       |      OK |
CalledNBR:    |       7 |       |      OK |
LOC:          |      52 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_alloc_gradient_field_3d (Begins at: 1236 Ends at: 1264)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       3 |       |      OK |
CalledNBR:    |       5 |       |      OK |
LOC:          |      29 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_free_gradient_field_3d (Begins at: 1266 Ends at: 1290)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       4 |       |      OK |
LOC:          |      25 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_copy_gradient_field_3d (Begins at: 1293 Ends at: 1360)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       4 |       |      OK |
LOC:          |      68 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

N_compute_gradient_field_3d (Begins at: 1362 Ends at: 1545)
--------------+---------+-------+---------+
Complexity:   |      13 |       |      OK |
ParamNBR:     |       6 |     * |         |
CalledNBR:    |      40 |     * |         |
LOC:          |     184 |     * |         |
--------------+---------+-------+---------+
metrics are OK

N_compute_gradient_field_components_3d (Begins at: 1548 Ends at: 1597)
--------------+---------+-------+---------+
Complexity:   |       7 |       |      OK |
ParamNBR:     |       4 |       |      OK |
CalledNBR:    |      10 |       |      OK |
LOC:          |      50 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

Clone analysis:

This file has 13 potentially cloned functions:
  N_copy_gradient_neighbours_y  N_copy_gradient_neighbours_x  N_alloc_gradient_3d  N_alloc_gradient_2d  N_create_gradient_neighbours_y  N_create_gradient_neighbours_x  N_copy_gradient_neighbours_z  N_copy_gradient_2d  N_alloc_gradient_neighbours_z  N_alloc_gradient_neighbours_y  N_alloc_gradient_neighbours_x  N_free_gradient_field_2d  N_free_gradient_neighbours_2d

In lib/gpde/N_gradient.c clones of  N_copy_gradient_neighbours_x are:
	lib/gpde/N_gradient.c  N_copy_gradient_neighbours_y

In lib/gpde/N_gradient.c clones of  N_copy_gradient_neighbours_y are:
	lib/gpde/N_gradient.c  N_copy_gradient_neighbours_x

In lib/gpde/N_gradient.c clones of  N_create_gradient_neighbours_x are:
	lib/gpde/N_gradient.c  N_create_gradient_neighbours_y

In lib/gpde/N_gradient.c clones of  N_free_gradient_field_2d are:
	lib/gpde/N_gradient.c  N_free_gradient_neighbours_2d

In lib/gpde/N_gradient.c clones of  N_alloc_gradient_3d are:
	lib/gpde/N_gradient.c  N_alloc_gradient_2d

In lib/gpde/N_gradient.c clones of  N_alloc_gradient_neighbours_x are:
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_z
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_y

In lib/gpde/N_gradient.c clones of  N_create_gradient_neighbours_y are:
	lib/gpde/N_gradient.c  N_create_gradient_neighbours_x

In lib/gpde/N_gradient.c clones of  N_copy_gradient_2d are:
	lib/gpde/N_gradient.c  N_copy_gradient_neighbours_z

In lib/gpde/N_gradient.c clones of  N_alloc_gradient_2d are:
	lib/gpde/N_gradient.c  N_alloc_gradient_3d

In lib/gpde/N_gradient.c clones of  N_alloc_gradient_neighbours_z are:
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_y
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_x

In lib/gpde/N_gradient.c clones of  N_free_gradient_neighbours_2d are:
	lib/gpde/N_gradient.c  N_free_gradient_field_2d

In lib/gpde/N_gradient.c clones of  N_copy_gradient_neighbours_z are:
	lib/gpde/N_gradient.c  N_copy_gradient_2d

In lib/gpde/N_gradient.c clones of  N_alloc_gradient_neighbours_y are:
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_z
	lib/gpde/N_gradient.c  N_alloc_gradient_neighbours_x


__________________________________________

Threshold GRASS6 key metrics values at 2007-04-06 are:
---------------------------+-----------+---------+
                    median | upper     | outlier |
                           | quartile  | limit   |
---------------------------+-----------+---------+
Complexity (Cyclo):      5 |        25 |      37 |
ParamNBR:                2 |         6 |       8 |
CalledNBR:              10 |        60 |      87 |
LOC:                    43 |       195 |     272 |
---------------------------+-----------+---------+

Measures (see below Web page for details):
 Complexity (Cyclo): a complexity index
 ParamNBR: number of passed parameters
 CalledNBR: number of called functions
 LOC: Lines Of Code

Message interpretation:
 OK : Nothing to say at all
 *  : above 75 % of value warning
 ** : this is getting close to be out of range, consider revising the code
 ***: this is a monster, definitely you should revise this function


__________________________________________
Brought to you by:
SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory
http://web.soccerlab.polymtl.ca/grass-evolution/grass-browsers/grass-index-en.html




More information about the grass-qa mailing list