[GRASS-QA] GRASS QA: markus | ./grass6/lib/gis/opencell.c |2 clones ( alloc.c cats.c color_read.c find_cell.c get_row.c opencell.c )| 0 monsters | 1 warnings

grass-qa at proxy.soccerlab.polymtl.ca grass-qa at proxy.soccerlab.polymtl.ca
Wed Dec 13 10:37:31 EST 2006



Hello markus,

here a report on your recent GRASS-CVS change:

ANALYSIS

your changes to files/functions:


lib/gis/opencell.c functions


new_fileinfo (Begins at: 113 Ends at: 174)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      62 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_cell_old (Begins at: 178 Ends at: 233)
--------------+---------+-------+---------+
Complexity:   |       2 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       4 |       |      OK |
LOC:          |      56 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__open_cell_old (Begins at: 235 Ends at: 435)
--------------+---------+-------+---------+
Complexity:   |      22 |     * |         |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |      42 |     * |         |
LOC:          |     201 |    ** | Warning |
--------------+---------+-------+---------+
at least 1 values are close to an outlier please consider revising code

G_open_cell_new (Begins at: 461 Ends at: 468)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |       8 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_cell_new_random (Begins at: 470 Ends at: 477)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |       8 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_cell_new_uncompressed (Begins at: 479 Ends at: 486)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |       8 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_want_histogram (Begins at: 488 Ends at: 493)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       0 |       |      OK |
LOC:          |       6 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_set_cell_format (Begins at: 496 Ends at: 509)
--------------+---------+-------+---------+
Complexity:   |       4 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       0 |       |      OK |
LOC:          |      14 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_cellvalue_format (Begins at: 511 Ends at: 519)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       0 |       |      OK |
LOC:          |       9 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_fp_cell_new (Begins at: 521 Ends at: 544)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      24 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_fp_cell_new_uncompressed (Begins at: 547 Ends at: 568)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       3 |       |      OK |
LOC:          |      22 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

clean_check_raster_name (Begins at: 571 Ends at: 603)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       3 |       |      OK |
CalledNBR:    |      11 |       |      OK |
LOC:          |      33 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__open_raster_new (Begins at: 606 Ends at: 777)
--------------+---------+-------+---------+
Complexity:   |      17 |     * |         |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |      52 |     * |         |
LOC:          |     172 |     * |         |
--------------+---------+-------+---------+
metrics are OK

allocate_compress_buf (Begins at: 785 Ends at: 800)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      16 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__reallocate_work_buf (Begins at: 804 Ends at: 818)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      15 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__reallocate_null_buf (Begins at: 824 Ends at: 838)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      15 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__reallocate_mask_buf (Begins at: 843 Ends at: 857)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      15 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__reallocate_temp_buf (Begins at: 862 Ends at: 889)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       2 |       |      OK |
LOC:          |      28 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_set_fp_type (Begins at: 891 Ends at: 920)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       1 |       |      OK |
LOC:          |      30 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_raster_map_is_fp (Begins at: 922 Ends at: 954)
--------------+---------+-------+---------+
Complexity:   |       4 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       7 |       |      OK |
LOC:          |      33 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_raster_map_type (Begins at: 956 Ends at: 986)
--------------+---------+-------+---------+
Complexity:   |       4 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       8 |       |      OK |
LOC:          |      31 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_raster_map_type2 (Begins at: 988 Ends at: 1018)
--------------+---------+-------+---------+
Complexity:   |       4 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       8 |       |      OK |
LOC:          |      31 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_get_raster_map_type (Begins at: 1020 Ends at: 1024)
--------------+---------+-------+---------+
Complexity:   |       1 |       |      OK |
ParamNBR:     |       1 |       |      OK |
CalledNBR:    |       0 |       |      OK |
LOC:          |       5 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G__check_fp_type (Begins at: 1028 Ends at: 1083)
--------------+---------+-------+---------+
Complexity:   |       8 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |      21 |       |      OK |
LOC:          |      56 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_raster_new (Begins at: 1085 Ends at: 1101)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       5 |       |      OK |
LOC:          |      17 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_open_raster_new_uncompressed (Begins at: 1103 Ends at: 1132)
--------------+---------+-------+---------+
Complexity:   |       3 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       6 |       |      OK |
LOC:          |      30 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

G_set_quant_rules (Begins at: 1134 Ends at: 1161)
--------------+---------+-------+---------+
Complexity:   |       5 |       |      OK |
ParamNBR:     |       2 |       |      OK |
CalledNBR:    |       8 |       |      OK |
LOC:          |      28 |       |      OK |
--------------+---------+-------+---------+
metrics are OK

Clone analysis:

This file has 2 potentially cloned functions:
  G_raster_map_type2  G_raster_map_type

In lib/gis/opencell.c clones of  G_raster_map_type2 are:
	lib/gis/opencell.c  G_raster_map_type

In lib/gis/opencell.c clones of  G_raster_map_type are:
	lib/gis/opencell.c  G_raster_map_type2


__________________________________________

Threshold GRASS6 key metrics values at 2006-12-13 are:
---------------------------+-----------+---------+
                    median | upper     | outlier |
                           | quartile  | limit   |
---------------------------+-----------+---------+
Complexity (Cyclo):      5 |        25 |      37 |
ParamNBR:                2 |         6 |       8 |
CalledNBR:              10 |        60 |      86 |
LOC:                    42 |       190 |     265 |
---------------------------+-----------+---------+

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