TUDE EMPIRIQUE EN GNIE LOGICIEL Application sur Git

  • Slides: 46
Download presentation
ÉTUDE EMPIRIQUE EN GÉNIE LOGICIEL Application sur Git. Hub et Alexa Xavier Blanc –

ÉTUDE EMPIRIQUE EN GÉNIE LOGICIEL Application sur Git. Hub et Alexa Xavier Blanc – IUF – Bordeaux Univ. - Pro. Myze 02/10/2020 EJCP - Strasbourg - Juin 2019 1

Génie Logiciel ■ Le génie logiciel repose sur l’application systématique des connaissances, méthodes, compétences

Génie Logiciel ■ Le génie logiciel repose sur l’application systématique des connaissances, méthodes, compétences scientifiques et technologiques nécessaires à la modélisation, l’implémentation, les tests, la maintenance et la documentation de ces logiciels qui structurent de plus en plus notre société. ■ La recherche en génie logiciel fédère l’ensemble des activités qui permettent de définir, formaliser et évaluer les concepts, méthodes et outils qui portent la production logicielle actuelle et future. 02/10/2020 EJCP - Strasbourg - Juin 2019 2

Exemple : Performance Site Web 02/10/2020 EJCP - Strasbourg - Juin 2019 3

Exemple : Performance Site Web 02/10/2020 EJCP - Strasbourg - Juin 2019 3

Exemple : Performance Site Web Faire peu de requêtes CSS améliore la performance !

Exemple : Performance Site Web Faire peu de requêtes CSS améliore la performance ! 02/10/2020 EJCP - Strasbourg - Juin 2019 4

Comment Evaluer ? 02/10/2020 EJCP - Strasbourg - Juin 2019 5

Comment Evaluer ? 02/10/2020 EJCP - Strasbourg - Juin 2019 5

Etude Empirique : Observation & Expérimentation ■ Les études empiriques permettent d’évaluer des concepts,

Etude Empirique : Observation & Expérimentation ■ Les études empiriques permettent d’évaluer des concepts, méthodes et outils en réalisant des expérimentations et en observant les résultats obtenus 02/10/2020 EJCP - Strasbourg - Juin 2019 6

1. ETUDES QUANTATIVES 02/10/2020 EJCP - Strasbourg - Juin 2019 7

1. ETUDES QUANTATIVES 02/10/2020 EJCP - Strasbourg - Juin 2019 7

Définition ■ Quantitative: quantifying a relationship or comparing two or more groups. Identify a

Définition ■ Quantitative: quantifying a relationship or comparing two or more groups. Identify a cause-effect. 02/10/2020 EJCP - Strasbourg - Juin 2019 8

Principles Cause Effect Theory Observation 02/10/2020 Treatment Outcome Independent variable Dependent variable EJCP -

Principles Cause Effect Theory Observation 02/10/2020 Treatment Outcome Independent variable Dependent variable EJCP - Strasbourg - Juin 2019 9

Concepts ■ Dependent variable (response variable): the studied variable ■ Independent variables: variables that

Concepts ■ Dependent variable (response variable): the studied variable ■ Independent variables: variables that can be either controlled or manipulated. ■ Factors: independent variables that will change (manipulated) ■ Treatment: Value of a factor Ind. vars 02/10/2020 EJCP - Strasbourg - Juin 2019 Object Dep. var 10

Process Idea 1. Definition 2. Planning 3. Operation 4. Analysis & Interpretation 5. Package

Process Idea 1. Definition 2. Planning 3. Operation 4. Analysis & Interpretation 5. Package Þ Conclusion 02/10/2020 EJCP - Strasbourg - Juin 2019 11

Definition: Goal Template ■ Analyze <Object(s) of study> ■ For the purpose of <Purpose>

Definition: Goal Template ■ Analyze <Object(s) of study> ■ For the purpose of <Purpose> ■ With respect to their <Quality focus> ■ From the point of vies of the <Perspective> ■ In the context of <Context> 02/10/2020 EJCP - Strasbourg - Juin 2019 12

Definition: Examples Object Purpose Quality Focus Perspective Context Product Characterize Effectiveness Developer Student Process

Definition: Examples Object Purpose Quality Focus Perspective Context Product Characterize Effectiveness Developer Student Process Monitor Cost Modifier Project Metric Predict Reliability Maintainer Large software Theory Control Maintenability Project Manager OSS Change Portability Customer Senior User Researcher 02/10/2020 EJCP - Strasbourg - Juin 2019 13

Planning: 7 steps 1. Context selection 2. Hypothesis formulation 3. Variables selection 4. Selection

Planning: 7 steps 1. Context selection 2. Hypothesis formulation 3. Variables selection 4. Selection of subjects 5. Experiment design 6. Instrumentation 7. Validity evaluation Þ Experiment design 02/10/2020 EJCP - Strasbourg - Juin 2019 14

Planning: 1 - context selection Trade-off between cost and generalisation ■ Student vs Professionals

Planning: 1 - context selection Trade-off between cost and generalisation ■ Student vs Professionals ■ Toy vs real software ■ Off-line vs on-line 02/10/2020 EJCP - Strasbourg - Juin 2019 15

Planning: 2 - Hypothesis ■ Null hypothesis (H 0): No effect. – So we

Planning: 2 - Hypothesis ■ Null hypothesis (H 0): No effect. – So we expect to reject it ! ■ Alternative hypothesis (Ha, H 1, etc. ): Effect. – We expect to accept it! ■ Type-I-Error: Reject H 0 although it is true (Conclude that there is an effect although there is no). – P(Type-I-Error)=P(reject H 0 | H 0 is true) ■ Type-II-Error: Not reject H 0 although it is false (Conclude that there is no effect although there is one). – P(Type-II-Error)=P(not reject H 0 | H 0 is false) 02/10/2020 EJCP - Strasbourg - Juin 2019 16

Planning: 3 – Variables Selection ■ Independent Variables: – No advice or guideline. –

Planning: 3 – Variables Selection ■ Independent Variables: – No advice or guideline. – Requires domain knowledge. – Include the choice of the scale. ■ Dependent Variables: – Support for the hypothesis. – Have to be easily measurable (!metrics aggregation). 02/10/2020 EJCP - Strasbourg - Juin 2019 17

Planning: 4 – Selection of Subjects ■ Large impact on the generalisation ■ Randomized

Planning: 4 – Selection of Subjects ■ Large impact on the generalisation ■ Randomized – Pure random – Quota – Blocked 02/10/2020 EJCP - Strasbourg - Juin 2019 18

Planning 5 – Experiment Design ■ One factor with two treatments ■ One factor

Planning 5 – Experiment Design ■ One factor with two treatments ■ One factor with more than two treatments ■ Two factors with two treatments ■ More than two factors each with two treatments 02/10/2020 EJCP - Strasbourg - Juin 2019 19

Planning 6 - Instrumentation ■ Objects ■ Guidelines ■ Measurement 02/10/2020 EJCP - Strasbourg

Planning 6 - Instrumentation ■ Objects ■ Guidelines ■ Measurement 02/10/2020 EJCP - Strasbourg - Juin 2019 20

Planning 7 – Validity evaluation ■ Conclusion validity – Low statistical power, … ■

Planning 7 – Validity evaluation ■ Conclusion validity – Low statistical power, … ■ Internal validity – History, maturity, … ■ Construct validity – Mono-method bias, … ■ External validity – Selection, … 02/10/2020 EJCP - Strasbourg - Juin 2019 21

Analysis ■ Descriptive Statitics ■ Data set reduction ■ Hypothesis testing 02/10/2020 EJCP -

Analysis ■ Descriptive Statitics ■ Data set reduction ■ Hypothesis testing 02/10/2020 EJCP - Strasbourg - Juin 2019 22

Analysis: Descriptive Statistics scale Central tendency Dispersion Nominal Mode Frequency Ordinal Median Interval of

Analysis: Descriptive Statistics scale Central tendency Dispersion Nominal Mode Frequency Ordinal Median Interval of variation Interval Mean Standard deviation, variance Ratio Geometric mean Coefficient of variation 02/10/2020 EJCP - Strasbourg - Juin 2019 23

Analysis: Outliers ■ Remove data that clearly does not fit the sample • •

Analysis: Outliers ■ Remove data that clearly does not fit the sample • • • • outlier Scatter plots 02/10/2020 EJCP - Strasbourg - Juin 2019 24

Analysis: Hypothesis Testing 1/2 ■ Rewrite the null hypothesis according to the measure –

Analysis: Hypothesis Testing 1/2 ■ Rewrite the null hypothesis according to the measure – Ex: one factor, two treatments => same probability p(A)=p(B)=1/2 ■ Test Error-I : p(Reject Ho | Ho is true) – p(Reject | p(A)=p(B)=1/2) – If we have 15 tests. P(4 or less) = 0. 059, P(5 or less) = 0. 1509. If we obtain 4 or less A then, this is not due to hazard. If we obtain 5 or less, then it may be due to hazard. – 0, 1, 2, 3 or 4 => reject – 5, 6 … => cannot reject 02/10/2020 EJCP - Strasbourg - Juin 2019 25

Analysis: Hypothesis Testing 2/2 ■ Find the test that fits your design – Chi

Analysis: Hypothesis Testing 2/2 ■ Find the test that fits your design – Chi 2, F-Test, T-Test, Cor. Test, Anova, 02/10/2020 EJCP - Strasbourg - Juin 2019 26

Example ■ Goal: Show that our tool improves efficiency for developers to evolve their

Example ■ Goal: Show that our tool improves efficiency for developers to evolve their software ■ H 0 : time needed to realize an evolution is the same with or without our tool (one factor, two treatment) – t-test to compare the mean (check normal law) ■ Two groups (with and without our tool) ■ Object: realize one evolution on an existing product 02/10/2020 EJCP - Strasbourg - Juin 2019 27

Ref “Experimentation in Software Engineering, An introduction”. C. Wohlin, P. Runeson, M. Höst, M.

Ref “Experimentation in Software Engineering, An introduction”. C. Wohlin, P. Runeson, M. Höst, M. C. Ohlsson, B. Regnell, A. Wesslén. Kluwer Academic Publishers. 02/10/2020 EJCP - Strasbourg - Juin 2019 28

Exemple : Performance Site Web ■ Objectif : – Il faut faire « peu

Exemple : Performance Site Web ■ Objectif : – Il faut faire « peu » de requêtes CSS ■ Planning : https: //github. com/xblanc 33/cssoptimizationfinder. git – Contexte – Step 1 – Hypothèse, Instrumentation – Step 2 – Evaluation – Step 3 02/10/2020 EJCP - Strasbourg - Juin 2019 29

Exercice : Ownership Il faut que les développeurs soient propriétaires 02/10/2020 EJCP - Strasbourg

Exercice : Ownership Il faut que les développeurs soient propriétaires 02/10/2020 EJCP - Strasbourg - Juin 2019 30

Exercice : Turnover Il faut un peu de turnover 02/10/2020 EJCP - Strasbourg -

Exercice : Turnover Il faut un peu de turnover 02/10/2020 EJCP - Strasbourg - Juin 2019 31

Exercices … ■ Le clean code permet d’éviter des bugs (permet une maintenance moins

Exercices … ■ Le clean code permet d’éviter des bugs (permet une maintenance moins cher) ■ Le couplage est source de bug ■ Le typage permet d’éviter des bugs – http: //earlbarr. com/publications/typestudy. pdf [ICSE 2017] 02/10/2020 EJCP - Strasbourg - Juin 2019 32

MSR : Exploiter les plates-formes Git ■ https: //github. com/search/advanced ■ https: //www. softwareheritage.

MSR : Exploiter les plates-formes Git ■ https: //github. com/search/advanced ■ https: //www. softwareheritage. org/mission/an-essential-infrastructure-forscience/? lang=fr ■ https: //github. com/jrfaller/diggit 02/10/2020 EJCP - Strasbourg - Juin 2019 33

2. ETUDES QUALITATIVES Il y a les statistiques et la vraie vie ! 02/10/2020

2. ETUDES QUALITATIVES Il y a les statistiques et la vraie vie ! 02/10/2020 EJCP - Strasbourg - Juin 2019 34

Numbers, numbers … 02/10/2020 EJCP - Strasbourg - Juin 2019 35

Numbers, numbers … 02/10/2020 EJCP - Strasbourg - Juin 2019 35

Laboratory vs real world Ind. vars Object Dep. var Object 02/10/2020 EJCP - Strasbourg

Laboratory vs real world Ind. vars Object Dep. var Object 02/10/2020 EJCP - Strasbourg - Juin 2019 36

Qualitative vs Quantitative 02/10/2020 Quantitative Qualitative Objective Quantify and generalize Measure the incidence Understand

Qualitative vs Quantitative 02/10/2020 Quantitative Qualitative Objective Quantify and generalize Measure the incidence Understand motivation or reasons Uncover trends Sample Large number of subjects Small number of nonrepresentative cases Data Analysis Statistical Non-statistical EJCP - Strasbourg - Juin 2019 37

Objectives ■ discover new ideas from data instead of testing pre-designed research questions 02/10/2020

Objectives ■ discover new ideas from data instead of testing pre-designed research questions 02/10/2020 EJCP - Strasbourg - Juin 2019 38

Method 02/10/2020 EJCP - Strasbourg - Juin 2019 39

Method 02/10/2020 EJCP - Strasbourg - Juin 2019 39

Ref ■ « Real World Research » , C. Robson, K. Mc. Cartan 02/10/2020

Ref ■ « Real World Research » , C. Robson, K. Mc. Cartan 02/10/2020 EJCP - Strasbourg - Juin 2019 40

Exemple : Themis 02/10/2020 EJCP - Strasbourg - Juin 2019 41

Exemple : Themis 02/10/2020 EJCP - Strasbourg - Juin 2019 41

Exemple : Performance Site Web ■ Pourquoi certains sites n’ont pas de CSS ?

Exemple : Performance Site Web ■ Pourquoi certains sites n’ont pas de CSS ? ■ Qui décide de l’intégration des CSS dans le HTML ? Et quand ? 02/10/2020 EJCP - Strasbourg - Juin 2019 42

Exemple : Linters ■ Pourquoi les développeurs n’exploitent-ils pas les linters ? ■ Pourquoi

Exemple : Linters ■ Pourquoi les développeurs n’exploitent-ils pas les linters ? ■ Pourquoi les testeurs ont du mal à introduire de la diversité dans leur tests ? 02/10/2020 EJCP - Strasbourg - Juin 2019 43

SYNTHÈSE 02/10/2020 EJCP - Strasbourg - Juin 2019 44

SYNTHÈSE 02/10/2020 EJCP - Strasbourg - Juin 2019 44

■ Evaluation quantitative et qualitative ■ Mise en œuvre (coût) ■ Retours terrain 02/10/2020

■ Evaluation quantitative et qualitative ■ Mise en œuvre (coût) ■ Retours terrain 02/10/2020 EJCP - Strasbourg - Juin 2019 45

Exemple : Exploratory Testing ■ Approche Hybride 02/10/2020 EJCP - Strasbourg - Juin 2019

Exemple : Exploratory Testing ■ Approche Hybride 02/10/2020 EJCP - Strasbourg - Juin 2019 46