[GRASS-QA] GRASS QA: mmetz |statusstructure.cc grid.h viewshed.cc rbbst.cc ...| no clones | 1 monsters |4 warnings

soccerlab.info at gmail.com soccerlab.info at gmail.com
Mon Feb 21 01:46:13 EST 2011


Hello mmetz,

here's a report on your recent grass-SVN change for the revision : 45442 

ANALYSIS 

your changes to files/class/methods/functions : 

*****************************************************************
          File :/raster/r.viewshed/statusstructure.cc
*****************************************************************

          Function
get_vertical_angle(Begins at: 67, Ends at:82)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       2 |       |           OK |         2 |
ParamNBR:     |       3 |     * |      WARNING |         3 |
CalledNBR:    |       7 |       |           OK |         7 |
LOC:          |      16 |       |           OK |        16 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       WARNING           |
-----------------------------------------------------------+
 at least 1 values are close to an outlier please consider revising code!


calculate_dist_n_gradient(Begins at: 107, Ends at:132)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       3 |       |           OK |         3 |
ParamNBR:     |       2 |       |           OK |         2 |
CalledNBR:    |       5 |       |           OK |         5 |
LOC:          |      26 |       |           OK |        26 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :/raster/r.viewshed/grid.h
*****************************************************************

The system don't find class, method and function
 in this file during analysis!
*****************************************************************
          File :/raster/r.viewshed/viewshed.cc
*****************************************************************

          Function
viewshed_external(Begins at: 428, Ends at:618)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      10 |     * |      WARNING |        10 |
ParamNBR:     |       4 |     * |      WARNING |         4 |
CalledNBR:    |      50 |    ** | BABY-MONSTER |        50 |
LOC:          |     191 |    ** | BABY-MONSTER |       191 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


viewshed_in_memory(Begins at: 203, Ends at:411)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      10 |     * |      WARNING |        10 |
ParamNBR:     |       4 |     * |      WARNING |         4 |
CalledNBR:    |      53 |    ** | BABY-MONSTER |        53 |
LOC:          |     209 |    ** | BABY-MONSTER |       209 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :/raster/r.viewshed/rbbst.cc
*****************************************************************

          Function
find_max_value_within_key(Begins at: 636, Ends at:662)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       6 |       |           OK |         6 |
ParamNBR:     |       2 |       |           OK |         2 |
CalledNBR:    |       4 |       |           OK |         4 |
LOC:          |      27 |       |           OK |        27 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a            OK           |
-----------------------------------------------------------+
metrics are OK


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :/raster/r.viewshed/visibility.h
*****************************************************************

          Class
IJCompare(Begins at: 264, Ends at:268)
             +--------+--------+--------+--------+--------+--------+
             |    DIT |    NOC |    WMC |    RFC |    CBO |   LCOM |
+------------+--------+--------+--------+--------+--------+--------|
|NEW Metrics |      1 |      0 |      0 |      1 |      0 |      0 |
+------------+--------+--------+--------+--------+--------+--------|
|OLD Metrics |        |        |        |        |        |        |
+------------+--------+--------+--------+--------+--------+--------+



Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :/raster/r.viewshed/distribute.cc
*****************************************************************

The system don't find class, method and function
 in this file during analysis!
*****************************************************************
          File :/raster/r.viewshed/main.cc
*****************************************************************

          Function
parse_args(Begins at: 493, Ends at:687)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |       8 |    ** | BABY-MONSTER |         8 |
ParamNBR:     |       7 |    ** | BABY-MONSTER |         7 |
CalledNBR:    |      56 |     * |      WARNING |        56 |
LOC:          |     195 |     * |      WARNING |       195 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a  BABY-MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


main(Begins at: 125, Ends at:482)
--------------+---------+-------+--------------+-----------+
              |          New Metrics           |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity:   |      11 |     * |      WARNING |        11 |
ParamNBR:     |       2 |       |           OK |         2 |
CalledNBR:    |     100 |   *** |      MONSTER |       100 |
LOC:          |     358 |   *** |      MONSTER |       358 |
--------------+---------+-------+--------------+-----------+
Conclusion:   | this function is a       MONSTER           |
-----------------------------------------------------------+
 metric are OUT OF RANGE!


Clone analysis:
This file does not contain cloned functions

*****************************************************************
          File :/raster/r.viewshed/statusstructure.h
*****************************************************************

The system don't find class, method and function
 in this file during analysis!
*****************************************************************
          File :/raster/r.viewshed/eventlist.cc
*****************************************************************

The system don't find class, method and function
 in this file during analysis!
*****************************************************************
          File :/raster/r.viewshed/grass.cc
*****************************************************************

The system don't find class, method and function
 in this file during analysis!
____________________________________________


Threshold grass key metrics values at Mon Feb 21 01:45:54 EST 2011 are:
----------------------+-----------+-----------+-----------+
                      | warning   | middle    | extrem    |
                      | limits    | limits    | limits    |
----------------------+-----------+-----------+-----------+
Complexity (Cyclo):   |         9 |        19 |        30 |
ParamNBR:             |         3 |         6 |         9 |
CalledNBR:            |        17 |        41 |        65 |
LOC:                  |        66 |       148 |       231 |
----------------------+-----------+-----------+-----------+



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 
    -Global analysis: based on 21 metrics(the fourth preceding include)

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

Conclusion interpretation :
    CORRECT     : if all metrics are situated before warning limits
    WARNING     : if 1 to more metrics are between warning and middle limits
    BABY_MONSTER: if 1 to more metrics are between middle and extreme limits
    MONSTERS    : if 1 to more metrics are in the extreme limits


_______________________________________________
Brought to you by :
	SOftware Cost-effective Change and Evolution Research (SOCCER) laboratory 

Please visite our web site on your project at :
    http://web.soccerlab.polymtl.ca/project-manager/grass-website/index.html


More information about the grass-qa mailing list