CN109583476A - Software metrics method, system and electronic equipment based on software development process - Google Patents

Software metrics method, system and electronic equipment based on software development process Download PDF

Info

Publication number
CN109583476A
CN109583476A CN201811302823.4A CN201811302823A CN109583476A CN 109583476 A CN109583476 A CN 109583476A CN 201811302823 A CN201811302823 A CN 201811302823A CN 109583476 A CN109583476 A CN 109583476A
Authority
CN
China
Prior art keywords
software
team
user
activity
index
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811302823.4A
Other languages
Chinese (zh)
Other versions
CN109583476B (en
Inventor
宁德军
王煜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Advanced Research Institute of CAS
Original Assignee
Shanghai Advanced Research Institute of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Advanced Research Institute of CAS filed Critical Shanghai Advanced Research Institute of CAS
Priority to CN201811302823.4A priority Critical patent/CN109583476B/en
Publication of CN109583476A publication Critical patent/CN109583476A/en
Application granted granted Critical
Publication of CN109583476B publication Critical patent/CN109583476B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/213Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
    • G06F18/2135Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods based on approximation criteria, e.g. principal component analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design

Abstract

The present invention provides a kind of software metrics method, system and electronic equipment based on software development process, the system comprises: data acquisition module, for obtaining the data of each dimension of software, as Elementary Measures member;Preprocessing module, for the part Elementary Measures member of selection to be converted into derived measurement member;Software metrics module obtains software quality index, user's activity index, team's activity index and health status perception index etc. for handling according to preset software metric model the Elementary Measures member of input and the derived measurement member.The present invention comprehensively and accurately portrays open source projects from the dimensions such as user's activity, team's activity, software quality, generate the software metric model based on software development process, use the software metric model, user's activity index, team's activity index, software quality index and the health status perception index etc. of open source projects can quickly be calculated, the objective understanding software condition of helper applications team, finds the problem in time.

Description

Software metrics method, system and electronic equipment based on software development process
Technical field
The present invention relates to data mining technology fields, more particularly to a kind of software metrics side based on software development process Method, system and electronic equipment.
Background technique
Principal component analysis (Principal Component Analysis, abbreviation PCA) is related between investigating multiple variables Property a kind of multivariate statistical method, how research to disclose the internal structure between multiple variables by a few principal component, i.e., from Export a few principal component in original variable, them made to retain the information of original variable as much as possible, and to each other mutually not It is related.Processing usually mathematically is exactly that original multiple indexs are made linear combination, as new overall target.
Crawler technology is the program of a kind of " automation browse network ", it according to certain rules, automatically on the world wide web (www Grab the information that user needs.With the development of internet, network becomes the carrier of bulk information.Crawler technology also becomes data The important component of acquisition is a step the most basic in big data analysis.In addition to web crawlers, numerous platforms are also open The data-interface of oneself, facilitates developer to access, such as Github, microblogging.
In internet+epoch, Open Source Software with it free, open source code, transparent procedures, without using the features such as limitation Immense success is obtained, definition, design, exploitation and the use process of open source software are by the volunteer of numerous professions with the group of socialization The basic mode of body concurrent development is completed.At the same time, open source community such as Github etc. is due to a large amount of high-quality open source items of trustship Mesh and obtain pursuing for numerous software developers.However, there is also a large amount of unsuccessful projects in Github open source community, according to system Meter, Github open source community shares ten thousand project more than 8000, wherein only 5,350,000 or so projects account for 6.7% by star.Therefore, such as What is quickly found out high-quality open source projects from magnanimity project is particularly important for numerous developers study, participation;On the other hand, The objective level for understanding developed software of numerous software team how is helped, finds the problem in time, actively takes countermeasure, make Open source projects healthy and sustainable development is very urgent.
Summary of the invention
In order to solve above-mentioned and other potential technical problems, the embodiment provides one kind to be based on software The software metrics system of development process, the software metrics system based on software development process includes: data acquisition module, is used In the data for obtaining each dimension of software, as Elementary Measures member;Preprocessing module, the part Elementary Measures member for that will choose turn Change derived measurement member into;Software metrics module, for the Elementary Measures member according to preset software metric model to input It is handled with the derived measurement member, obtains software quality index, user's activity index, team's activity index and health status Perceive index.
In one embodiment of the invention, the software metrics system based on software development process further include: training number According to module is obtained, for obtaining open source software data according to filter condition;Correlating module, for soft based on the open source Number of packages evidence carries out correlation analysis two-by-two to derived measurement member and Elementary Measures member, and according to correlation analysis result by each institute It states measurement metric and is mapped to user's activity dimension, team's activity dimension, software quality dimension;Principal component analysis module, respectively to institute The measurement metric principal component analysis for stating user's activity dimension, team's activity dimension, the software quality dimension, obtains user The calculation formula of activity index, team's activity index and software quality index;Software metric model generation module is based on the use The calculation formula of family activity index, team's activity index and software quality index generates the software metric model.
In one embodiment of the invention, the principal component analysis module includes: user's activity index unit, to the use Activity dimension relevant measurement metric in family carries out principal component analysis and obtains user's active principle constituting, and obtain user's activity it is main at The weight coefficient divided obtains the user according to the weight coefficient of user's active principle and user's active principle The calculation formula of activity index;Team's activity index unit carries out principal component to the relevant measurement metric of team's activity dimension Analysis obtains team's active principle and constitutes, and obtains the weight coefficient of team's active principle, according to team's activity master The weight coefficient of ingredient and team's active principle obtains the calculation formula of team's activity index;Software quality index Unit carries out principal component analysis to the relevant measurement metric of the software quality dimension, obtains software quality principal component and constitutes, and obtains The weight coefficient for taking the software quality principal component, according to the power of the software quality principal component and the software quality principal component Weight coefficient obtains the software quality index.
In one embodiment of the invention, user's active principle is user's activity, user's active principle Weight coefficient be 1, the calculation formula of user's activity index are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1 For user's activity.
In one embodiment of the invention, team's active principle include code cooperation efficiency, team exploitation heartbeat, Team's code change speed;Wherein, the code cooperation efficiency is made of three measurement metrics: average request aggregate speed is averaged Aggregate speed, contributor's number;Team's exploitation heartbeat is made of two measurement metrics: publication heartbeat and internal development rate; Team's code change speed is made of two measurement metrics: code change speed and averagely submission speed;Team's activity index ftvCalculation formula it is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、 wtv2、wtv3The respectively weight coefficient of code cooperation efficiency, the team exploitation weight coefficient of heartbeat, team's code change speed Weight coefficient.
In one embodiment of the invention, the software quality principal component includes: code size and quality, software reliability And community's ability of maintenance, software O&M ability;Wherein, the code size and quality are made of two measurement metrics: lines of code With the thousand row bit error rates;The software reliability and community's ability of maintenance are made of two measurement metrics: defect closing velocity and problem Comment on temperature;The software O&M ability is made of defect closing rate;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software fortune Dimension ability;wsq1、wsq2、wsq3The respectively power of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of weight coefficient, software O&M ability.
In one embodiment of the invention, the software metric model includes: the calculation formula of user's activity index, team The calculation formula of activity index and the calculation formula of software quality index;Based on user's activity index, team's activity index, software The health status of performance figure perceives formula of index.
In one embodiment of the invention, the data acquisition module passes through web crawlers method and repository API approach The data of each dimension of the software are obtained from software repository.
The embodiment of the present invention also provides a kind of software metrics method based on software development process, described to be opened based on software The software metrics method of hair process includes: to obtain the data of each dimension of software, as Elementary Measures member;The part of selection is basic Measurement metric is converted into derived measurement member;According to preset software metric model to the Elementary Measures member of input and the derivation Measurement metric is handled, and is obtained software quality index, user's activity index, team's activity index and health status and is perceived index.
In one embodiment of the invention, the software metrics method based on software development process further include: according to mistake Filter condition obtains open source software data;Based on the open source software data, derived measurement member and Elementary Measures member are carried out two-by-two Correlation analysis, and according to correlation analysis result by each measurement metric be mapped to user's activity dimension, team's activity dimension, Software quality dimension;Respectively to the measurement metric of user's activity dimension, team's activity dimension, the software quality dimension Principal component analysis, obtains user's activity index, the calculation formula of team's activity index and software quality index;Based on the use The calculation formula of family activity index, team's activity index and software quality index generates the software metric model.
It is described respectively to user's activity dimension, team's activity dimension, described in one embodiment of the invention The measurement metric principal component of software quality dimension is analyzed, and user's activity index, team's activity index and software quality index are obtained Calculation formula specifically include: to the relevant measurement metric of user's activity dimension carry out principal component analysis obtain user's activity master Ingredient is constituted, and obtains the weight coefficient of user's active principle, according to user's active principle and user activity The weight coefficient of principal component obtains the calculation formula of user's activity index;Measurement metric relevant to team's activity dimension It carries out principal component analysis and obtains team's active principle composition, and obtain the weight coefficient of team's active principle, according to described The weight coefficient of team's active principle and team's active principle obtains the calculation formula of team's activity index;It is right The relevant measurement metric of the software quality dimension carries out principal component analysis, obtains software quality principal component and constitutes, and described in obtaining The weight coefficient of software quality principal component, according to the weight coefficient of the software quality principal component and the software quality principal component Obtain the software quality index.
In one embodiment of the invention, user's active principle is user's activity, user's active principle Weight coefficient be 1, the calculation formula of user's activity index are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1 For user's activity.
In one embodiment of the invention, team's active principle include code cooperation efficiency, team exploitation heartbeat, Team's code change speed;Wherein, the code cooperation efficiency is made of three measurement metrics: average request aggregate speed is averaged Aggregate speed, contributor's number;Team's exploitation heartbeat is made of two measurement metrics: publication heartbeat and internal development rate; Team's code change speed is made of two measurement metrics: code change speed and averagely submission speed;Team's activity index ftvCalculation formula it is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、 wtv2、wtv3The respectively weight coefficient of code cooperation efficiency, the team exploitation weight coefficient of heartbeat, team's code change speed Weight coefficient.
In one embodiment of the invention, the software quality principal component includes: code size and quality, software reliability And community's ability of maintenance, software O&M ability;Wherein, the code size and quality are made of two measurement metrics: lines of code With the thousand row bit error rates;The software reliability and community's ability of maintenance are made of two measurement metrics: defect closing velocity and problem Comment on temperature;The software O&M ability is made of defect closing rate;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software fortune Dimension ability;wsq1、wsq2、wsq3The respectively power of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of weight coefficient, software O&M ability.
In one embodiment of the invention, the software metric model includes: the calculation formula of user's activity index, team The calculation formula of activity index and the calculation formula of software quality index;Based on user's activity index, team's activity index, software The health status of performance figure perceives formula of index.
In one embodiment of the invention, obtained from software repository by web crawlers method and repository API approach Take the data of each dimension of the software.
The embodiment of the present invention also provides a kind of electronic equipment, including processor and memory, and the memory is stored with Program instruction, the electronic equipment include the software metrics system based on software development process as described above;Or the place It manages device operation program instruction and realizes the software metrics method based on software development process as described above.
As described above, software metrics method, system and the electronic equipment of the invention based on software development process have with It is lower the utility model has the advantages that
The present invention is based on open source projects data, using correlation analysis, principal component analysis, clustering etc., from The dimensions such as family activity, team's activity, software quality comprehensively and accurately portray open source projects, generate based on software The software metric model of development process, using the software metric model, the user's activity that can quickly calculate open source projects refers to Number, team's activity index, software quality index and health status perceive index etc., and helper applications team comprehensively, objectively understands The situation of developed software, finds the problem in time, actively takes measures, and helps open source projects healthy and sustainable development, helps to develop Person quickly has found high-quality project-based Learning and participation from magnanimity open source projects.
Detailed description of the invention
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the invention, for For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings other Attached drawing.
Fig. 1 is shown as the whole functional block diagram of the software metrics system of the invention based on software development process.
Fig. 2 is shown as the principle of principal component analysis module in the software metrics system of the invention based on software development process Block diagram.
Fig. 3 is shown as the overall flow schematic diagram of the software metrics method of the invention based on software development process.
Fig. 4 be shown as software metric model in the software metrics system of the invention based on software development process generate it is whole Body flow diagram.
Fig. 5 is shown as obtaining the calculation formula of each index in the software metrics method of the invention based on software development process Flow chart.
Fig. 6 is shown as the specific implementation procedure flow chart of the software metrics method of the invention based on software development process.
Fig. 7 is shown as software metric model in the software metrics method and system of the invention based on software development process Schematic diagram of calculation result.
Component label instructions
The 100 software metrics systems based on software development process
110 data acquisition modules
120 preprocessing modules
130 software metrics modules
140 training datas obtain module
150 correlating modules
160 principal component analysis modules
161 user's activity index units
162 team's activity index units
163 software quality index units
170 software metric model generation modules
S110~S170 step
S161~S163 step
Specific embodiment
Illustrate embodiments of the present invention below by way of specific specific example, those skilled in the art can be by this specification Other advantages and efficacy of the present invention can be easily understood for disclosed content.The present invention can also pass through in addition different specific realities The mode of applying is embodied or practiced, the various details in this specification can also based on different viewpoints and application, without departing from Various modifications or alterations are carried out under spirit of the invention.It should be noted that in the absence of conflict, following embodiment and implementation Feature in example can be combined with each other.
Fig. 1 is please referred to Fig. 7.It should be clear that this specification structure depicted in this specification institute accompanying drawings, ratio, size etc., only to Cooperate the revealed content of specification, so that those skilled in the art understands and reads, being not intended to limit the invention can be real The qualifications applied, therefore do not have technical essential meaning, the tune of the modification of any structure, the change of proportionate relationship or size It is whole, in the case where not influencing the effect of present invention can be generated and the purpose that can reach, it should all still fall in disclosed skill Art content obtains in the range of capable of covering.Meanwhile in this specification it is cited as "upper", "lower", "left", "right", " centre " and The term of " one " etc. is merely convenient to being illustrated for narration, rather than to limit the scope of the invention, relativeness It is altered or modified, under the content of no substantial changes in technology, when being also considered as the enforceable scope of the present invention.
The present embodiment is a kind of software metrics system and method based on software development process, is based on open source community Github In based on 70,000 entry data, using correlation analysis, principal component analysis, clustering etc., in conjunction with field of software engineering Expertise comprehensively and accurately portrays open source projects from the dimensions such as user's activity, team's activity, software quality, raw At the software metric model based on software development process.Using the software metric model, open source projects can be quickly calculated User's activity index, team's activity index, software quality index and health status perception index etc., helper applications team is objective Understand software condition, find the problem in time, so that open source projects obtain the lasting development of health.
The principle of the software metrics system and method based on software development process of the present embodiment described in detail below and Embodiment, make those skilled in the art do not need creative work be appreciated that the present embodiment based on software development process Software metrics system and method.
As shown in Figure 1, the embodiment provides the described software metrics system 100 based on software development process to It less include: data acquisition module 110, preprocessing module 120 and software metrics module 130.
In this present embodiment, the data acquisition module 110 is used to obtain the data of each dimension of software, as Elementary Measures Member.
Specifically, in this present embodiment, the data acquisition module 110 passes through web crawlers method and the repository side API Method obtains the data of each dimension of the software from software repository.
Such as the data acquisition module 110 uses web crawlers technology and repository API technology, obtains each dimension of software Data, the data of each dimension of software include time series data and static data, as Elementary Measures member.
In this present embodiment, the preprocessing module 120 is used to the part Elementary Measures member of selection being converted into derivation degree Amount member.Such as by Elementary Measures member: the timing information that code is submitted is converted into average submission this derived measurement of speed member.
In this present embodiment, the software metrics module 130 is used for according to preset software metric model to the institute of input It states Elementary Measures member and the derived measurement member is handled, obtain software quality index, user's activity index, team's activity and refer to Several and health status perception index etc..
When concrete application, software metrics can be used by the data of the Elementary Measures member and derived measurement member Model directly obtains software quality index, user's activity index, team's activity index etc..For the feelings of part measurement metric missing Condition automatically analyzes computable index, and provides corresponding result.For example, lacking the measurement metric for calculating team's activity index, then lead to It crosses software metric model and obtains software quality index, user's activity index, provide corresponding as a result, ignoring the meter of team's activity index It calculates.
It in this present embodiment, further include establishing software metric model.As shown in Figure 1, described based on software development process Software metrics system 100 further include: training data obtains module 140, correlating module 150, principal component analysis module 160 And software metric model generation module 170.
Specifically, in this present embodiment, the training data obtains module 140 and is used to obtain high-quality open according to filter condition Source software data.Specifically, filter condition is set to obtain the information of high-quality software for released version number isometry member.Example Such as, to lines of code, whether there is or not released version etc. carry out condition filter, to obtain the information of high-quality open source software.
In this present embodiment, the correlating module 150 is used to be based on the open source software data, to derived measurement Member and Elementary Measures member carry out correlation analysis two-by-two, and each measurement metric is mapped to user according to correlation analysis result Active dimension, team's activity dimension, software quality dimension.
Specifically, based on each dimension data of high-quality software, according to correlation analysis as a result, in conjunction with field of software engineering Derived measurement member and part Elementary Measures member are mapped to higher level software quality dimension by expertise, user's activity is tieed up Degree, team's activity dimension.
In this present embodiment, the principal component analysis module 160 is respectively to user's activity dimension, team activity The measurement metric principal component analysis of dimension, the software quality dimension, obtains user's activity index, team's activity index and software The calculation formula of performance figure.
Specifically, in this present embodiment, as shown in Fig. 2, the principal component analysis module 160 includes: user's activity index Unit 161, team's activity index unit 162 and software quality index unit 163.
In this present embodiment, user's activity index unit 161 to the relevant measurement metric of user's activity dimension into Row principal component analysis obtains user's active principle and constitutes, and obtains the weight coefficient of user's active principle, according to the use The weight coefficient of family active principle and user's active principle obtains the calculation formula of user's activity index.
Specifically, in this present embodiment, user's active principle is user's activity, user's active principle Weight coefficient is 1, the calculation formula of user's activity index are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1For User's activity.
In this present embodiment, team's activity index unit 162 to the relevant measurement metric of team's activity dimension into Row principal component analysis obtains team's active principle and constitutes, and obtains the weight coefficient of team's active principle, according to the group The weight coefficient of team's active principle and team's active principle obtains the calculation formula of team's activity index.
Specifically, in this present embodiment, team's active principle include code cooperation efficiency, team exploitation heartbeat, Team's code change speed;Wherein, the code cooperation efficiency is made of three measurement metrics: average request aggregate speed is averaged Aggregate speed, contributor's number;Team's exploitation heartbeat is made of two measurement metrics: publication heartbeat and internal development rate; Team's code change speed is made of two measurement metrics: code change speed and averagely submission speed;Team's activity index ftvCalculation formula it is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、 wtv2、wtv3The respectively weight coefficient of code cooperation efficiency, the team exploitation weight coefficient of heartbeat, team's code change speed Weight coefficient.
In this present embodiment, the software quality index unit 163 to the relevant measurement metric of the software quality dimension into Row principal component analysis obtains software quality principal component and constitutes, and obtains the weight coefficient of the software quality principal component, according to institute The weight coefficient for stating software quality principal component and the software quality principal component obtains the software quality index.
Specifically, in this present embodiment, the software quality principal component includes: code size and quality, software reliability And community's ability of maintenance, software O&M ability;Wherein, the code size and quality are made of two measurement metrics: lines of code With the thousand row bit error rates;The software reliability and community's ability of maintenance are made of two measurement metrics: defect closing velocity and problem Comment on temperature;The software O&M ability is made of defect closing rate;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software fortune Dimension ability;wsq1、wsq2、wsq3The respectively power of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of weight coefficient, software O&M ability.
Specifically, in this present embodiment, the software metric model generation module 170 be based on user's activity index, Team's activity index and the calculation formula of software quality index generate the software metric model.
In this present embodiment, the software metric model includes: the calculation formula of user's activity index, team's activity index Calculation formula and software quality index calculation formula;Based on user's activity index, team's activity index, software quality index Health status perceive formula of index.
As shown in figure 3, the embodiment of the present invention also provides a kind of software metrics method based on software development process, it is described Software metrics method based on software development process includes:
Step S110 obtains the data of each dimension of software, as Elementary Measures member.
In this present embodiment, it is obtained from software repository by web crawlers method and repository API approach described soft The data of each dimension of part.
Such as the data acquisition module 110 uses web crawlers technology and repository API technology, obtains each dimension of software Data, the data of each dimension of software include time series data and static data, as Elementary Measures member.
The part Elementary Measures member of selection is converted into derived measurement member by step S120.
Such as by Elementary Measures member: the timing information that code is submitted is converted into average submission this derived measurement of speed member.
Step S130, according to preset software metric model to the Elementary Measures member of input and derived measurement member It is handled, obtains software quality index, user's activity index, team's activity index and health status perception index etc..
When concrete application, software can be used directly by the data of the Elementary Measures member and derived measurement member Measurement model directly obtains software quality index, user's activity index, team's activity index etc..It is lacked for part measurement metric The case where, computable index is automatically analyzed, and provide corresponding result.For example, lack the measurement metric for calculating team's activity index, Software quality index, user's activity index are then obtained by software metric model, provided corresponding as a result, ignoring team's activity index Calculating.
As shown in figure 4, the present embodiment further includes the process that building generates software metric model.
Specifically, in this present embodiment, as shown in figure 4, the software metrics method based on software development process is also wrapped It includes:
Step S140 obtains high-quality open source software data according to filter condition
Step S150 is based on the open source software data, carries out correlation two-by-two to derived measurement member and Elementary Measures member Analysis, and each measurement metric is mapped to by user's activity dimension, team's activity dimension, software matter according to correlation analysis result Measure dimension;
Step S160, respectively to the degree of user's activity dimension, team's activity dimension, the software quality dimension First principal component analysis is measured, user's activity index, the calculation formula of team's activity index and software quality index are obtained;
Step S170, the calculation formula based on user's activity index, team's activity index and software quality index are raw At the software metric model.
Those skilled in the art, can be direct when executing the software metrics method of the invention based on software development process Step S110 to step S130 is executed, can also then execute step S140 after executing the step S110 and step S120 To step S170, step S130 is then executed again.
In this present embodiment, as shown in figure 5, it is described respectively to user's activity dimension, team's activity dimension, institute The measurement metric principal component analysis for stating software quality dimension, obtains user's activity index, team's activity index and software quality and refers to Several calculation formula specifically include:
Step S161, to the relevant measurement metric of user's activity dimension carry out principal component analysis obtain user activity it is main at Divide and constitute, and obtain the weight coefficient of user's active principle, according to user's active principle and user's activity master The weight coefficient of ingredient obtains the calculation formula of user's activity index.
In this present embodiment, user's active principle is user's activity, the weight system of user's active principle Number is 1, the calculation formula of user's activity index are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1It is living for user Property.
Step S162, to the relevant measurement metric of team's activity dimension carry out principal component analysis obtain team activity it is main at Divide and constitute, and obtain the weight coefficient of team's active principle, according to team's active principle and team's activity master The weight coefficient of ingredient obtains the calculation formula of team's activity index.
In this present embodiment, team's active principle includes code cooperation efficiency, team exploitation heartbeat, team's code Pace of change;Wherein, the code cooperation efficiency is made of three measurement metrics: average request aggregate speed, averagely aggregate speed, Contributor's number;Team's exploitation heartbeat is made of two measurement metrics: publication heartbeat and internal development rate;Team's generation Code pace of change is made of two measurement metrics: code change speed and averagely submission speed;Team activity index ftvCalculating it is public Formula is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、 wtv2、wtv3The respectively weight coefficient of code cooperation efficiency, the team exploitation weight coefficient of heartbeat, team's code change speed Weight coefficient.
Step S163 carries out principal component analysis to the relevant measurement metric of the software quality dimension, obtains software quality master Ingredient is constituted, and obtains the weight coefficient of the software quality principal component, according to the software quality principal component and the software The weight coefficient of quality principal component obtains the software quality index.
In this present embodiment, the software quality principal component includes: code size and quality, software reliability and community's dimension Shield ability, software O&M ability;Wherein, the code size and quality are made of two measurement metrics: lines of code and thousand rows miss Code rate;The software reliability and community's ability of maintenance are made of two measurement metrics: defect closing velocity and problem comment on temperature; The software O&M ability is made of defect closing rate;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software fortune Dimension ability;wsq1、wsq2、wsq3The respectively power of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of weight coefficient, software O&M ability.
In this present embodiment, the software metric model includes: the calculation formula of user's activity index, team's activity index Calculation formula and software quality index calculation formula;Based on user's activity index, team's activity index, software quality index Health status perceive formula of index.
Therefore the software metrics method and system in the present embodiment uses crawler technology, correlation analysis, principal component Analysis etc. carries out data mining to 70,000 entry data in collected open source community Github, in conjunction with field of software engineering Expertise, ultimately generate using with activity index, team's activity index, software quality index as the software metric model of core, The objective situation for understanding institute's exploration project of helper applications team, finds the problem in time, actively takes measures, obtain open source projects The lasting development of health.The model can also quickly find high-quality project from magnanimity open source projects, learn for developer and participate in.
The embodiment of the present invention also provides a kind of electronic equipment, including processor and memory, and the memory is stored with Program instruction, the electronic equipment include the software metrics system 100 based on software development process as described above;Or it is described Processor runs program instruction and realizes the software metrics method based on software development process as described above.
It is above-mentioned to the software metrics system 100 based on software development process and the software degree based on software development process Amount method is described in detail, and details are not described herein.
Wherein, the electronic equipment is, for example, smart phone, PAD, PC or server etc..It can will be based on soft The software metrics system 100 of part development process and the software metrics method based on software development process carry out operation and execute corresponding function The execution electronic equipment of energy.
As shown in fig. 6, by taking the open source projects in open source community Github generate software metric model as an example.
1) firstly, using web crawlers technology and repository API technology, each dimension of software is obtained from Github repository Data, including code the static datas such as time series datas and licensing such as submits, and as Elementary Measures member, total about 70,000 are opened The information of source item.
Based on 70,000 Github repository data, Elementary Measures member is converted into derived measurement member, as submitted code Timing information is converted into average submission this derived measurement of speed member.Ultimately generate 15 measurement metrics as shown in table 1 below.
Table 1
To lines of code, whether there is or not released versions etc. to carry out condition filter, to obtain the information of high-quality open source software.Data are pre- Nearly 8,000 project datas are obtained after processing.
2) nearly 8,000 open source projects data based on acquisition carry out correlation two-by-two to 1) middle 15 measurement metrics generated Analysis, to further appreciate that the correlation between measurement metric, based on correlation analysis as a result, in conjunction with it in field of software engineering Concrete meaning maps that software quality dimension, team's activity dimension, user's activity dimension.Between dimension and measurement metric Physical relationship is as shown in table 2.
Table 2
3) it is directed to user's activity dimension, PCA analysis is carried out to star number, attention number, software duplication 3 measurement metrics of number, is extracted 1 principal component x outuv1, adding up load quadratic sum is more than 90%, remains most information, and it is living can to fully describe user Property.It is analyzed according to PCA as a result, calculating user's activity index fuv, calculation formula is as follows:
fuv=xuv1
For team's activity dimension, to code change speed, speed, average request aggregate speed, average conjunction are averagely submitted And 7 speed, contributor's number, publication heartbeat, internal development rate measurement metrics progress PCA analyses, extract 3 principal components xtv1、xtv2、xtv3, accumulative variance contribution ratio reaches 84.477%, remains most information, and it is living can to fully describe team Property.First principal component xtv1It is made of average request aggregate speed, average aggregate speed, contributor's number, representative is to create point Branch submits the efficiency for merging the Github code collaboration process based on request etc., with Github Flow Efficiency table Show;Second principal component, xtv2It is made of publication heartbeat, internal development rate, represents team's exploitation heartbeat, use Team Heartbeat is indicated;Third principal component xtv3By code change speed, averagely submit speed constituted, represent team's code change Speed, indicated with CodeChange Speed.According to PCA Analysis result calculation team activity index ftv, calculation formula is as follows:
Wherein wi(i=tv1, tv2, tv3) is each principal component weight, calculation method are as follows: wi=variance percentage/accumulation side Poor percentage.
For software quality dimension, lines of code, the thousand row bit error rates, defect closing velocity, defect closing rate, problem are commented PCA analysis is carried out by 5 measurement metrics of temperature, extracts 3 principal component xsq1, xsq2, xsq3, contribution rate of accumulative total 78.497% connects Nearly 80%, most information are remained, software quality can be fully described.Wherein first principal component xsq1By lines of code, thousand The row bit error rate is constituted, and open source projects code size and quality are represented, and is indicated with Software Scale&Quality, and second is main Ingredient xsq2It is made of defect closing velocity, problem comment temperature, represents software reliability and community's ability of maintenance, illustrate society Help of the area to software maintenance is indicated with Community Based Reliability;Third principal component xsq3It is closed by defect Rate is constituted, and is represented open source projects software O&M ability, is indicated with Software Maintenance Capability.
According to PCA Analysis result calculation software quality index fsq, calculation formula is as follows:
Wherein wi(i=sq1, sq2, sq3) is each principal component weight, calculation method are as follows: wi=variance percentage/accumulation side Poor percentage.
4) it is based on user's activity index, team's activity index, software quality index, it is soft can objectively to perceive open source comprehensively The situation of user, team, the software itself of part etc. according to the sum of three, can also obtain the health status perception of open source projects Index HSPI.
HSPI=fuv+ftv+fsq
User's activity index of the direct software for calculation of software metric model as shown in Figure 7, group can be used in software team Team's activity index and software quality index carry out the situation of complete perception project.The case where for software section measurement metric missing, from The dynamic computable index of analysis, and provide corresponding result.
In conclusion the present invention based on open source projects data, is divided using correlation analysis, principal component analysis, cluster Analysis etc., comprehensively and accurately portrays open source projects from the dimensions such as user's activity, team's activity, software quality, is generated Software metric model based on software development process can quickly calculate the use of open source projects using the software metric model Family activity index, team's activity index, software quality index and health status perception index etc., helper applications team is comprehensive, objective The situation of the developed software of the understanding of sight, finds the problem in time, actively takes measures, and helps open source projects healthy and sustainable development, Developer is helped quickly to find high-quality project-based Learning and participation from magnanimity open source projects.So the present invention effectively overcomes now There is the various shortcoming in technology and has high industrial utilization value.
The above-described embodiments merely illustrate the principles and effects of the present invention, and is not intended to limit the present invention.It is any ripe The personage for knowing this technology all without departing from the spirit and scope of the present invention, carries out modifications and changes to above-described embodiment.Cause This, includes that institute is complete without departing from the spirit and technical ideas disclosed in the present invention for usual skill in technical field such as At all equivalent modifications or change, should be covered by the claims of the present invention.

Claims (17)

1. a kind of software metrics system based on software development process, which is characterized in that described based on the soft of software development process Part gauging system includes:
Data acquisition module, for obtaining the data of each dimension of software, as Elementary Measures member;
Preprocessing module, for the part Elementary Measures member of selection to be converted into derived measurement member;
Software metrics module, for according to preset software metric model to input the Elementary Measures member and the derivation degree Amount member is handled, and is obtained software quality index, user's activity index, team's activity index and health status and is perceived index.
2. the software metrics system according to claim 1 based on software development process, which is characterized in that described based on soft The software metrics system of part development process further include:
Training data obtains module, for obtaining open source software data according to filter condition;
Correlating module carries out two-by-two derived measurement member and Elementary Measures member for being based on the open source software data Correlation analysis, and according to correlation analysis result by each measurement metric be mapped to user's activity dimension, team's activity dimension, Software quality dimension;
Principal component analysis module, respectively to user's activity dimension, team's activity dimension, the software quality dimension The analysis of measurement metric principal component, obtains user's activity index, the calculation formula of team's activity index and software quality index;
Software metric model generation module, based on user's activity index, team's activity index and software quality index It calculates formula and generates the software metric model.
3. the software metrics system according to claim 2 based on software development process, which is characterized in that the principal component Analysis module includes:
User's activity index unit carries out principal component analysis to the relevant measurement metric of user's activity dimension and obtains user's activity Principal component is constituted, and obtains the weight coefficient of user's active principle, living according to user's active principle and the user The weight coefficient of property principal component obtains the calculation formula of user's activity index;
Team's activity index unit carries out principal component analysis to the relevant measurement metric of team's activity dimension and obtains team's activity Principal component is constituted, and obtains the weight coefficient of team's active principle, living according to team's active principle and the team The weight coefficient of property principal component obtains the calculation formula of team's activity index;
Software quality index unit carries out principal component analysis to the relevant measurement metric of the software quality dimension, obtains software matter It measures principal component to constitute, and obtains the weight coefficient of the software quality principal component, according to the software quality principal component and described The weight coefficient of software quality principal component obtains the software quality index.
4. the software metrics system according to claim 3 based on software development process, which is characterized in that the user is living Property principal component be user's activity, the weight coefficient of user's active principle is 1, the calculation formula of user's activity index Are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1For user's activity.
5. the software metrics system according to claim 3 based on software development process, it is characterised in that: the team is living Property principal component include code cooperation efficiency, team exploitation heartbeat, team's code change speed;Wherein, the code cooperation efficiency It is made of three measurement metrics: average request aggregate speed, average aggregate speed, contributor's number;Team exploitation heartbeat by Two measurement metrics are constituted: publication heartbeat and internal development rate;Team's code change speed is made of two measurement metrics: generation Code pace of change and averagely submission speed;Team activity index ftvCalculation formula it is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、wtv2、 wtv3Respectively the weight coefficient of code cooperation efficiency, team's exploitation weight coefficient of heartbeat, team's code change speed weight Coefficient.
6. the software metrics system according to claim 3 based on software development process, which is characterized in that the software matter Measuring principal component includes: code size and quality, software reliability and community's ability of maintenance, software O&M ability;Wherein, the generation Code scale and quality are made of two measurement metrics: lines of code and the thousand row bit error rates;The software reliability and community safeguard energy Power is made of two measurement metrics: defect closing velocity and problem comment on temperature;The software O&M ability is by defect closing rate structure At;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software O&M energy Power;wsq1、wsq2、wsq3The respectively weight system of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of number, software O&M ability.
7. the software metrics system according to claim 2 to 6 any claim based on software development process, feature It is, the software metric model includes: the calculation formula of user's activity index, the calculation formula of team's activity index and software The calculation formula of performance figure;Health status perception based on user's activity index, team's activity index, software quality index refers to Number calculation formula.
8. the software metrics system according to claim 1 based on software development process, which is characterized in that the data are adopted Collection module obtains the data of each dimension of the software by web crawlers method and repository API approach from software repository.
9. a kind of software metrics method based on software development process, which is characterized in that described based on the soft of software development process Part measure includes:
The data for obtaining each dimension of software, as Elementary Measures member;
The part Elementary Measures member of selection is converted into derived measurement member;
The Elementary Measures member of input and the derived measurement member are handled according to preset software metric model, obtained Software quality index, user's activity index, team's activity index and health status perceive index.
10. the software metrics method according to claim 9 based on software development process, which is characterized in that described to be based on The software metrics method of software development process further include:
Open source software data are obtained according to filter condition;
Based on the open source software data, correlation analysis two-by-two is carried out to derived measurement member and Elementary Measures member, and according to phase Each measurement metric is mapped to user's activity dimension, team's activity dimension, software quality dimension by closing property analysis result;
Respectively to the measurement metric principal component of user's activity dimension, team's activity dimension, the software quality dimension Analysis obtains user's activity index, the calculation formula of team's activity index and software quality index;
Calculation formula based on user's activity index, team's activity index and software quality index generates the software metrics Model.
11. the software metrics method according to claim 10 based on software development process, which is characterized in that the difference Measurement metric principal component analysis to user's activity dimension, team's activity dimension, the software quality dimension, obtains The calculation formula of user's activity index, team's activity index and software quality index specifically includes:
Principal component analysis is carried out to the relevant measurement metric of user's activity dimension and obtains user's active principle composition, and is obtained The weight coefficient of user's active principle, according to the weight coefficient of user's active principle and user's active principle Obtain the calculation formula of user's activity index;
Principal component analysis is carried out to the relevant measurement metric of team's activity dimension and obtains team's active principle composition, and is obtained The weight coefficient of team's active principle, according to the weight coefficient of team's active principle and team's active principle Obtain the calculation formula of team's activity index;
Principal component analysis is carried out to the relevant measurement metric of the software quality dimension, software quality principal component is obtained and constitutes, and obtain The weight coefficient for taking the software quality principal component, according to the power of the software quality principal component and the software quality principal component Weight coefficient obtains the software quality index.
12. the software metrics method according to claim 11 based on software development process, which is characterized in that the user Active principle is user's activity, and the weight coefficient of user's active principle is 1, and the calculating of user's activity index is public Formula are as follows: fuv=xuv1;Wherein, fuvFor user's activity index, xuv1For user's activity.
13. the software metrics method according to claim 11 based on software development process, which is characterized in that the team Active principle includes code cooperation efficiency, team exploitation heartbeat, team's code change speed;Wherein, the code cooperation effect Rate is made of three measurement metrics: average request aggregate speed, average aggregate speed, contributor's number;The team develops heartbeat It is made of two measurement metrics: publication heartbeat and internal development rate;Team's code change speed is made of two measurement metrics: Code change speed and averagely submission speed;Team activity index ftvCalculation formula it is as follows:
Wherein: xtv1、xtv2、xtv3Respectively code cooperation efficiency, team develop heartbeat, team's code change speed;wtv1、wtv2、 wtv3Respectively the weight coefficient of code cooperation efficiency, team's exploitation weight coefficient of heartbeat, team's code change speed weight Coefficient.
14. the software metrics method according to claim 11 based on software development process, which is characterized in that the software Quality principal component includes: code size and quality, software reliability and community's ability of maintenance, software O&M ability;Wherein, described Code size and quality are made of two measurement metrics: lines of code and the thousand row bit error rates;The software reliability and community's maintenance Ability is made of two measurement metrics: defect closing velocity and problem comment on temperature;The software O&M ability closes rate by defect It constitutes;Software quality index fsqCalculation formula it is as follows:
Wherein: xsq1、xsq2、xsq3Respectively code size and quality, software reliability and community's ability of maintenance, software O&M energy Power;wsq1、wsq2、wsq3The respectively weight system of the weight coefficient of code size and quality, software reliability and community's ability of maintenance The weight coefficient of number, software O&M ability.
15. the software metrics side based on software development process described in 0 to 14 any claim according to claim 1 Method, which is characterized in that the software metric model includes: the calculating of the calculation formula of user's activity index, team's activity index The calculation formula of formula and software quality index;Based on user's activity index, team's activity index, the health of software quality index State aware formula of index.
16. the software metrics method according to claim 9 based on software development process, which is characterized in that pass through network Crawler method and repository API approach obtain the data of each dimension of the software from software repository.
17. a kind of electronic equipment, including processor and memory, the memory are stored with program instruction, which is characterized in that institute Stating electronic equipment includes the software based on software development process as described in claim 1 to claim 8 any claim Gauging system;Or the processor operation program instruction is realized such as claim 9 to the described in any item bases of claim 16 In the software metrics method of software development process.
CN201811302823.4A 2018-11-02 2018-11-02 Software measurement method and system based on software development process and electronic equipment Active CN109583476B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811302823.4A CN109583476B (en) 2018-11-02 2018-11-02 Software measurement method and system based on software development process and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811302823.4A CN109583476B (en) 2018-11-02 2018-11-02 Software measurement method and system based on software development process and electronic equipment

Publications (2)

Publication Number Publication Date
CN109583476A true CN109583476A (en) 2019-04-05
CN109583476B CN109583476B (en) 2022-10-18

Family

ID=65921258

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811302823.4A Active CN109583476B (en) 2018-11-02 2018-11-02 Software measurement method and system based on software development process and electronic equipment

Country Status (1)

Country Link
CN (1) CN109583476B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111723004A (en) * 2020-05-20 2020-09-29 时时同云科技(成都)有限责任公司 Measuring method for agile software development, measuring data output method and device
CN112069047A (en) * 2020-09-02 2020-12-11 鹏城实验室 Computational ecology detection method, device, equipment and storage medium
CN112698836A (en) * 2021-01-18 2021-04-23 昆明理工大学 Code quality attribute judgment method for complex user comments
CN112882914A (en) * 2021-03-09 2021-06-01 东南大学 Multi-dimensional measurement system for health of open-source software ecosystem
CN113778501A (en) * 2020-06-22 2021-12-10 北京沃东天骏信息技术有限公司 Code task processing method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107423911A (en) * 2017-08-02 2017-12-01 中国科学院上海高等研究院 Software Evaluating Degree of Success method/system, computer-readable recording medium and equipment
US20170371626A1 (en) * 2016-06-23 2017-12-28 International Business Machines Corporation Contextualized software component selection and repository generation

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170371626A1 (en) * 2016-06-23 2017-12-28 International Business Machines Corporation Contextualized software component selection and repository generation
CN107423911A (en) * 2017-08-02 2017-12-01 中国科学院上海高等研究院 Software Evaluating Degree of Success method/system, computer-readable recording medium and equipment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
吴超等: "基于生命周期的软件缺陷预测技术", 《计算机工程与设计》 *
王辉等: "基于软件信息库挖掘的软件缺陷预测方法", 《计算机工程与设计》 *

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111723004A (en) * 2020-05-20 2020-09-29 时时同云科技(成都)有限责任公司 Measuring method for agile software development, measuring data output method and device
CN111723004B (en) * 2020-05-20 2023-08-08 时时同云科技(成都)有限责任公司 Measurement method for agile software development, measurement data output method and device
CN113778501A (en) * 2020-06-22 2021-12-10 北京沃东天骏信息技术有限公司 Code task processing method and device
CN112069047A (en) * 2020-09-02 2020-12-11 鹏城实验室 Computational ecology detection method, device, equipment and storage medium
CN112069047B (en) * 2020-09-02 2023-02-07 鹏城实验室 Computational ecology detection method, device, equipment and storage medium
CN112698836A (en) * 2021-01-18 2021-04-23 昆明理工大学 Code quality attribute judgment method for complex user comments
CN112698836B (en) * 2021-01-18 2022-05-17 昆明理工大学 Code quality attribute judgment method for complex user comments
CN112882914A (en) * 2021-03-09 2021-06-01 东南大学 Multi-dimensional measurement system for health of open-source software ecosystem

Also Published As

Publication number Publication date
CN109583476B (en) 2022-10-18

Similar Documents

Publication Publication Date Title
CN109583476A (en) Software metrics method, system and electronic equipment based on software development process
Westerlund et al. The local power of the CADF and CIPS panel unit root tests
Kim et al. Development of a software education curriculum for secondary schools
Chen et al. Introducing cloud computing topics in curricula
França et al. Potential proposal to improve data transmission in healthcare systems
Matalonga et al. Testing context-aware software systems: Unchain the context, set it free!
Fusi et al. On the use of probabilistic worst-case execution time estimation for parallel applications in high performance systems
El-Attar A comparative study of students and professionals in syntactical model comprehension experiments
Ahmed et al. A brief history of HPC simulation and future challenges
Bevilacqua et al. Assessing the significance of the correlation between the components of a bivariate Gaussian random field
Sánchez et al. Soil: An agent-based social simulator in Python for modelling and simulation of social networks
Mokhtarzadeh et al. OpenColab project: OpenSim in Google colaboratory to explore biomechanics on the web
Getz et al. Using nova to construct agent-based models for epidemiological teaching and research
Grogan et al. Interactive models as a system design tool: Applications to system project management
Teramoto et al. An Education-Support PSE System: TSUNA-TASTE.
Gu et al. A test on meta-synthesis system approach to forecasting the GDP growth rate in China
Fard et al. Model And Simulation Scalability Traits For Interaction (Nexus) Modeling Of Water And Energy Systems
Evtushenko et al. Using simulation for performance analysis and visualization of parallel Branch-and-Bound methods
Shahriari et al. Webocd: A restful web-based overlapping community detection framework
Allen et al. A practical and comprehensive graduate course preparing students for research involving scientific computing
Dobre et al. Realistic simulation of large scale distributed systems using monitoring
Tan et al. Internet-based platform for power system simulating and planning
He et al. Research on the teaching mode of university virtual laboratory based on component technology
Paris et al. Packet Simulator Tool for Many-Core Systems
Yasudo et al. Analytical performance estimation for large-scale reconfigurable dataflow platforms

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant