Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Supervised MultiModal Integration Tool
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Baptiste Bauvin
Supervised MultiModal Integration Tool
Commits
fd1103b3
Commit
fd1103b3
authored
7 years ago
by
Baptiste Bauvin
Browse files
Options
Downloads
Patches
Plain Diff
Added logging commentary
parent
b279acb5
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Code/MonoMultiViewClassifiers/ExecClassif.py
+18
-8
18 additions, 8 deletions
Code/MonoMultiViewClassifiers/ExecClassif.py
with
18 additions
and
8 deletions
Code/MonoMultiViewClassifiers/ExecClassif.py
+
18
−
8
View file @
fd1103b3
...
...
@@ -171,16 +171,16 @@ def classifyOneIter_multicore(LABELS_DICTIONARY, argumentDictionaries, nbCores,
times
=
[
dataBaseTime
,
monoviewTime
,
multiviewTime
]
results
=
(
resultsMonoview
,
resultsMultiview
)
labelAnalysis
=
analyzeLabels
(
labels
,
trueLabels
,
results
,
directory
)
logging
.
debug
(
"
Start:
\t
Analyze
Global Results for iteration
"
)
logging
.
debug
(
"
Start:
\t
Analyze
Iteration Results
"
)
resultAnalysis
(
benchmark
,
results
,
args
.
name
,
times
,
metrics
,
directory
)
logging
.
debug
(
"
Done:
\t
Analyze
Global Results for iteration
"
)
logging
.
debug
(
"
Done:
\t
Analyze
Iteration Results
"
)
globalAnalysisTime
=
time
.
time
()
-
monoviewTime
-
dataBaseTime
-
start
-
multiviewTime
totalTime
=
time
.
time
()
-
start
logging
.
info
(
"
Extraction time :
"
+
str
(
dataBaseTime
)
+
"
s, Monoview time :
"
+
str
(
monoviewTime
)
+
"
s, Multiview Time :
"
+
str
(
multiviewTime
)
+
"
s,
Global
Analysis Time :
"
+
str
(
globalAnalysisTime
)
+
"
s,
Total
Duration :
"
+
str
(
totalTime
)
+
"
s
"
)
"
s,
Iteration
Analysis Time :
"
+
str
(
globalAnalysisTime
)
+
"
s,
Iteration
Duration :
"
+
str
(
totalTime
)
+
"
s
"
)
return
results
,
labelAnalysis
...
...
@@ -245,16 +245,16 @@ def classifyOneIter(LABELS_DICTIONARY, argumentDictionaries, nbCores, directory,
times
=
[
dataBaseTime
,
monoviewTime
,
multiviewTime
]
results
=
(
resultsMonoview
,
resultsMultiview
)
labelAnalysis
=
analyzeLabels
(
labels
,
trueLabels
,
results
,
directory
)
logging
.
debug
(
"
Start:
\t
Analyze
Global
Results
"
)
logging
.
debug
(
"
Start:
\t
Analyze
Iteration
Results
"
)
resultAnalysis
(
benchmark
,
results
,
args
.
name
,
times
,
metrics
,
directory
)
logging
.
debug
(
"
Done:
\t
Analyze
Global
Results
"
)
logging
.
debug
(
"
Done:
\t
Analyze
Iteration
Results
"
)
globalAnalysisTime
=
time
.
time
()
-
monoviewTime
-
dataBaseTime
-
start
-
multiviewTime
totalTime
=
time
.
time
()
-
start
logging
.
info
(
"
Extraction time :
"
+
str
(
dataBaseTime
)
+
"
s, Monoview time :
"
+
str
(
monoviewTime
)
+
"
s, Multiview Time :
"
+
str
(
multiviewTime
)
+
"
s,
Global
Analysis Time :
"
+
str
(
globalAnalysisTime
)
+
"
s,
Total
Duration :
"
+
str
(
totalTime
)
+
"
s
"
)
"
s,
Iteration
Analysis Time :
"
+
str
(
globalAnalysisTime
)
+
"
s,
Iteration
Duration :
"
+
str
(
totalTime
)
+
"
s
"
)
return
results
,
labelAnalysis
...
...
@@ -324,6 +324,7 @@ def execClassif(arguments):
directories
=
execution
.
genDirecortiesNames
(
directory
,
statsIter
)
if
statsIter
>
1
:
logging
.
debug
(
"
Start:
\t
Benchmark classification
"
)
for
statIterIndex
in
range
(
statsIter
):
if
not
os
.
path
.
exists
(
os
.
path
.
dirname
(
directories
[
statIterIndex
]
+
"
train_labels.csv
"
)):
try
:
...
...
@@ -368,6 +369,8 @@ def execClassif(arguments):
classificationIndices
[
iterIndex
],
kFolds
[
iterIndex
],
statsIterRandomStates
[
iterIndex
],
hyperParamSearch
,
metrics
,
DATASET
,
viewsIndices
,
dataBaseTime
,
start
,
benchmark
,
views
))
logging
.
debug
(
"
Done:
\t
Benchmark classification
"
)
logging
.
debug
(
"
Start:
\t
Global Results Analysis
"
)
classifiersIterResults
=
[]
iterLabelAnalysis
=
[]
for
result
in
iterResults
:
...
...
@@ -378,8 +381,12 @@ def execClassif(arguments):
classifiersNames
=
genNamesFromRes
(
mono
,
multi
)
analyzeIterLabels
(
iterLabelAnalysis
,
directory
,
classifiersNames
)
analyzeIterResults
(
classifiersIterResults
,
args
.
name
,
metrics
,
directory
)
logging
.
debug
(
"
Done:
\t
Global Results Analysis
"
)
totalDur
=
time
.
time
()
-
start
logging
.
info
(
"
Info:
\t
Total duration :
"
+
str
(
totalDur
))
else
:
logging
.
debug
(
"
Start:
\t
Benchmark classification
"
)
if
not
os
.
path
.
exists
(
os
.
path
.
dirname
(
directories
+
"
train_labels.csv
"
)):
try
:
os
.
makedirs
(
os
.
path
.
dirname
(
directories
+
"
train_labels.csv
"
))
...
...
@@ -393,6 +400,9 @@ def execClassif(arguments):
kFolds
,
statsIterRandomStates
,
hyperParamSearch
,
metrics
,
DATASET
,
viewsIndices
,
dataBaseTime
,
start
,
benchmark
,
views
)
logging
.
debug
(
"
Done:
\t
Benchmark classification
"
)
totalDur
=
time
.
time
()
-
start
logging
.
info
(
"
Info:
\t
Total duration :
"
+
str
(
totalDur
))
if
statsIter
>
1
:
pass
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment