Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
bob.bio.gmm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
bob
bob.bio.gmm
Commits
3e196947
There was a problem fetching the pipeline summary.
Commit
3e196947
authored
8 years ago
by
Tiago de Freitas Pereira
Browse files
Options
Downloads
Patches
Plain Diff
Preparing parallel isv
parent
d8ecc14c
Branches
paralell-isv
No related tags found
No related merge requests found
Pipeline
#
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
bob/bio/gmm/tools/isv.py
+5
-4
5 additions, 4 deletions
bob/bio/gmm/tools/isv.py
buildout.cfg
+1
-0
1 addition, 0 deletions
buildout.cfg
with
6 additions
and
4 deletions
bob/bio/gmm/tools/isv.py
+
5
−
4
View file @
3e196947
...
@@ -51,6 +51,7 @@ def isv_estep(algorithm, iteration, indices, force=False):
...
@@ -51,6 +51,7 @@ def isv_estep(algorithm, iteration, indices, force=False):
# Load data
# Load data
training_list
=
fs
.
training_list
(
'
projected_gmm
'
,
'
train_projector
'
,
arrange_by_client
=
True
)
training_list
=
fs
.
training_list
(
'
projected_gmm
'
,
'
train_projector
'
,
arrange_by_client
=
True
)
data
=
[
algorithm
.
read_gmm_stats
(
training_list
[
i
])
for
i
in
range
(
indices
[
0
],
indices
[
1
])]
data
=
[
algorithm
.
read_gmm_stats
(
training_list
[
i
])
for
i
in
range
(
indices
[
0
],
indices
[
1
])]
data_initialize
=
[
algorithm
.
read_gmm_stats
(
training_list
[
i
])
for
i
in
range
(
0
,
len
(
training_list
))]
# Load machine
# Load machine
if
iteration
:
if
iteration
:
...
@@ -61,8 +62,8 @@ def isv_estep(algorithm, iteration, indices, force=False):
...
@@ -61,8 +62,8 @@ def isv_estep(algorithm, iteration, indices, force=False):
# create new ISV Base
# create new ISV Base
isv_base
=
bob
.
learn
.
em
.
ISVBase
(
algorithm
.
ubm
,
algorithm
.
subspace_dimension_of_u
)
isv_base
=
bob
.
learn
.
em
.
ISVBase
(
algorithm
.
ubm
,
algorithm
.
subspace_dimension_of_u
)
# Perform the E-step
# Perform the E-step
trainer
.
initialize
(
isv_base
,
data
,
rng
=
algorithm
.
rng
)
#Just to reset the accumulators
trainer
.
initialize
(
isv_base
,
data
_initialize
,
rng
=
algorithm
.
rng
)
#Just to reset the accumulators
trainer
.
e_step
(
isv_base
,
data
)
trainer
.
e_step
(
isv_base
,
data
)
# write results to file
# write results to file
...
@@ -130,8 +131,8 @@ def isv_mstep(algorithm, iteration, number_of_parallel_jobs, force=False, clean=
...
@@ -130,8 +131,8 @@ def isv_mstep(algorithm, iteration, number_of_parallel_jobs, force=False, clean=
# Creates the IVectorTrainer and initialize values
# Creates the IVectorTrainer and initialize values
trainer
=
algorithm
.
isv_trainer
trainer
=
algorithm
.
isv_trainer
data
=
[
algorithm
.
read_gmm_stats
(
training_list
[
0
])
]
#Loading data just to allocate memory
data
_initialize
=
[
algorithm
.
read_gmm_stats
(
training_list
[
i
])
for
i
in
range
(
0
,
len
(
training_list
))]
trainer
.
initialize
(
isv_base
,
data
)
#Just to allocate memory
trainer
.
initialize
(
isv_base
,
data
_initialize
)
#Just to allocate memory
trainer
.
acc_u_a1
=
statistics
[
0
]
trainer
.
acc_u_a1
=
statistics
[
0
]
trainer
.
acc_u_a2
=
statistics
[
1
]
trainer
.
acc_u_a2
=
statistics
[
1
]
trainer
.
m_step
(
isv_base
)
# data is not used in M-step
trainer
.
m_step
(
isv_base
)
# data is not used in M-step
...
...
This diff is collapsed.
Click to expand it.
buildout.cfg
+
1
−
0
View file @
3e196947
...
@@ -12,3 +12,4 @@ verbose = true
...
@@ -12,3 +12,4 @@ verbose = true
[scripts]
[scripts]
recipe
=
bob.buildout:scripts
recipe
=
bob.buildout:scripts
dependent-scripts
=
true
dependent-scripts
=
true
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