[GRASS-QA] GRASS QA: mmetz |main.c global.h function.c | 13 clones
| 2 monsters |12 warnings
soccerlab.info at gmail.com
soccerlab.info at gmail.com
Sun Feb 13 05:26:23 EST 2011
Hello mmetz,
here's a report on your recent grass-SVN change for the revision : 45393
ANALYSIS
your changes to files/class/methods/functions :
*****************************************************************
File :/vector/v.kernel/main.c
*****************************************************************
Function
count_node_arcs(Begins at: 676, Ends at:689)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 4 | | OK | 4 |
LOC: | 14 | | OK | 14 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
compute_distance(Begins at: 791, Ends at:840)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 5 | | OK | 5 |
ParamNBR: | 8 | ** | BABY-MONSTER | 8 |
CalledNBR: | 6 | | OK | 6 |
LOC: | 50 | | OK | 50 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a BABY-MONSTER |
-----------------------------------------------------------+
metric are OUT OF RANGE!
main(Begins at: 73, Ends at:530)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 48 | *** | MONSTER | 48 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 155 | *** | MONSTER | 155 |
LOC: | 458 | *** | MONSTER | 458 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a MONSTER |
-----------------------------------------------------------+
metric are OUT OF RANGE!
L(Begins at: 38, Ends at:70)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 1 | | OK | 1 |
CalledNBR: | 12 | | OK | 12 |
LOC: | 33 | | OK | 33 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
compute_net_distance(Begins at: 692, Ends at:789)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 12 | * | WARNING | 12 |
ParamNBR: | 11 | *** | MONSTER | 11 |
CalledNBR: | 14 | | OK | 14 |
LOC: | 98 | * | WARNING | 98 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a MONSTER |
-----------------------------------------------------------+
metric are OUT OF RANGE!
compute_all_net_distances(Begins at: 599, Ends at:673)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 7 | | OK | 7 |
ParamNBR: | 5 | * | WARNING | 5 |
CalledNBR: | 18 | * | WARNING | 18 |
LOC: | 75 | * | WARNING | 75 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 3 values are close to an outlier please consider revising code!
Clone analysis:
This file has 1 potentially cloned functions:
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/main.c clones of compute_all_net_distances are:
/var/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/main.c compute_all_net_distances
*****************************************************************
File :/vector/v.kernel/global.h
*****************************************************************
The system don't find class, method and function
in this file during analysis!
*****************************************************************
File :/vector/v.kernel/function.c
*****************************************************************
Function
quarticKernel(Begins at: 166, Ends at:181)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
triangularKernel(Begins at: 132, Ends at:147)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 1 | | OK | 1 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
kernelFunction(Begins at: 217, Ends at:246)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 10 | * | WARNING | 10 |
ParamNBR: | 4 | * | WARNING | 4 |
CalledNBR: | 10 | | OK | 10 |
LOC: | 30 | | OK | 30 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 2 values are close to an outlier please consider revising code!
epanechnikovKernel(Begins at: 149, Ends at:164)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 1 | | OK | 1 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
euclidean_distance(Begins at: 87, Ends at:99)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 1 | | OK | 1 |
LOC: | 13 | | OK | 13 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
uniformKernel(Begins at: 115, Ends at:130)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 1 | | OK | 1 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
cosineKernel(Begins at: 200, Ends at:215)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
invGaussian2d(Begins at: 76, Ends at:83)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 1 | | OK | 1 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 8 | | OK | 8 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
triweightKernel(Begins at: 183, Ends at:198)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 3 | | OK | 3 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 2 | | OK | 2 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
gaussianKernel2(Begins at: 103, Ends at:111)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 1 | | OK | 1 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 3 | | OK | 3 |
LOC: | 9 | | OK | 9 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
kernel1(Begins at: 58, Ends at:73)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 2 | | OK | 2 |
ParamNBR: | 3 | * | WARNING | 3 |
CalledNBR: | 3 | | OK | 3 |
LOC: | 16 | | OK | 16 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a WARNING |
-----------------------------------------------------------+
at least 1 values are close to an outlier please consider revising code!
gaussian2dBySigma(Begins at: 9, Ends at:17)
--------------+---------+-------+--------------+-----------+
| New Metrics |Old Metrics|
--------------+---------+-------+--------------+-----------+
Complexity: | 1 | | OK | 1 |
ParamNBR: | 2 | | OK | 2 |
CalledNBR: | 1 | | OK | 1 |
LOC: | 9 | | OK | 9 |
--------------+---------+-------+--------------+-----------+
Conclusion: | this function is a OK |
-----------------------------------------------------------+
metrics are OK
Clone analysis:
This file has 12 potentially cloned functions:
cosineKernel uniformKernel epanechnikovKernel uniformKernel triangularKernel triangularKernel epanechnikovKernel quarticKernel triweightKernel quarticKernel cosineKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of quarticKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c triweightKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c cosineKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of triangularKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c uniformKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c epanechnikovKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of epanechnikovKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c uniformKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c triangularKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of uniformKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c triangularKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c epanechnikovKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of cosineKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c quarticKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c triweightKernel
In /data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c clones of triweightKernel are:
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c quarticKernel
/data/project-manager/grass/grassSVN/grass/trunk/vector/v.kernel/function.c cosineKernel
____________________________________________
Threshold grass key metrics values at Sun Feb 13 05:26:21 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