Spaces:
Sleeping
Sleeping
Vedant Pungliya
commited on
files
Browse files
{codenet_4000_finetuned_python_java → codenet_4000_finetuned_language_classification}/java/input.in
RENAMED
File without changes
|
{codenet_4000_finetuned_python_java → codenet_4000_finetuned_language_classification}/java/layer12/kmeans/clusters-kmeans-350.txt
RENAMED
The diff for this file is too large to render.
See raw diff
|
|
pert.py
CHANGED
@@ -45,7 +45,9 @@ perturbation_descriptions = {
|
|
45 |
"Casing Class Variable Modification": "Generates lexical variations of class and variable names with different casing.",
|
46 |
"Onecase Modification": "Generates lexical variations of class and variable names with just 1 letter uppercase wither for class anme or variable name.",
|
47 |
"Example Modification": "Generates lexical variations of class and variable names with Example being the class name and example being the variable name or vice versa.",
|
48 |
-
"Finetuned on compile error": "Clusters based on finetuned codebert model on compile errors"
|
|
|
|
|
49 |
}
|
50 |
|
51 |
def compute_and_log_csi(file_orig, file_pert, perturbation_name, output_csv="results/csi_summary.csv"):
|
@@ -170,4 +172,11 @@ compute_and_log_csi(
|
|
170 |
perturbation_name="Finetuned on compile error",
|
171 |
output_csv="results/csi_summary.csv"
|
172 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
173 |
# You can now call compute_and_log_csi again and again for other perturbations!
|
|
|
45 |
"Casing Class Variable Modification": "Generates lexical variations of class and variable names with different casing.",
|
46 |
"Onecase Modification": "Generates lexical variations of class and variable names with just 1 letter uppercase wither for class anme or variable name.",
|
47 |
"Example Modification": "Generates lexical variations of class and variable names with Example being the class name and example being the variable name or vice versa.",
|
48 |
+
"Finetuned on compile error": "Clusters based on finetuned codebert model on compile errors",
|
49 |
+
"Finetuned on language classification": "Clusters based on finetuned codebert model on language classification",
|
50 |
+
|
51 |
}
|
52 |
|
53 |
def compute_and_log_csi(file_orig, file_pert, perturbation_name, output_csv="results/csi_summary.csv"):
|
|
|
172 |
perturbation_name="Finetuned on compile error",
|
173 |
output_csv="results/csi_summary.csv"
|
174 |
)
|
175 |
+
|
176 |
+
compute_and_log_csi(
|
177 |
+
"codenet_4000_finetuned_language_classification/java/layer12/kmeans/clusters-kmeans-350.txt",
|
178 |
+
"codenet_4000_finetuned_language_classification/java/layer12/kmeans/clusters-kmeans-350.txt",
|
179 |
+
perturbation_name="Finetuned on language classification",
|
180 |
+
output_csv="results/csi_summary.csv"
|
181 |
+
)
|
182 |
# You can now call compute_and_log_csi again and again for other perturbations!
|
results/csi_summary.csv
CHANGED
@@ -12,3 +12,4 @@ Casing Class Variable Modification,0.6722713965133429,0.3277286034866571,Generat
|
|
12 |
Onecase Modification,0.665697304921991,0.334302695078009,Generates lexical variations of class and variable names with just 1 letter uppercase wither for class anme or variable name.
|
13 |
Example Modification,1.0,0.0,Generates lexical variations of class and variable names with Example being the class name and example being the variable name or vice versa.
|
14 |
Finetuned on compile error,1.0,0.0,Clusters based on finetuned codebert model on compile errors
|
|
|
|
12 |
Onecase Modification,0.665697304921991,0.334302695078009,Generates lexical variations of class and variable names with just 1 letter uppercase wither for class anme or variable name.
|
13 |
Example Modification,1.0,0.0,Generates lexical variations of class and variable names with Example being the class name and example being the variable name or vice versa.
|
14 |
Finetuned on compile error,1.0,0.0,Clusters based on finetuned codebert model on compile errors
|
15 |
+
Finetuned on language classification,1.0,0.0,Clusters based on finetuned codebert model on language classification
|