Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
bob.learn.tensorflow
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.learn.tensorflow
Merge requests
!15
Updates
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Updates
updates
into
master
Overview
0
Commits
7
Pipelines
1
Changes
2
Merged
Tiago de Freitas Pereira
requested to merge
updates
into
master
7 years ago
Overview
0
Commits
7
Pipelines
1
Changes
2
Expand
Patched the train.py script to accept tensors as input
Crafted a script that generates LFW pairs for validation
Implemented a validation mechanism using embeddings
0
0
Merge request reports
Viewing commit
b82ad522
Prev
Next
Show latest version
2 files
+
47
−
0
Side-by-side
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
b82ad522
Created debug features
· b82ad522
Tiago de Freitas Pereira
authored
7 years ago
bob/learn/tensorflow/script/load_and_debug.py
0 → 100644
+
46
−
0
Options
#!/usr/bin/env python
# vim: set fileencoding=utf-8 :
# @author: Tiago de Freitas Pereira <tiago.pereira@idiap.ch>
"""
Load and debug tensorflow models
Usage:
load_and_debug.py <configuration> <output-dir>
load_and_debug.py -h | --help
Options:
-h --help Show this screen.
"""
from
docopt
import
docopt
import
bob.io.base
import
os
import
numpy
import
imp
import
bob.learn.tensorflow
import
tensorflow
as
tf
import
logging
logger
=
logging
.
getLogger
(
"
bob.learn
"
)
def
main
():
args
=
docopt
(
__doc__
,
version
=
'
Mnist training with TensorFlow
'
)
output_dir
=
args
[
'
<output-dir>
'
]
config
=
imp
.
load_source
(
'
config
'
,
args
[
'
<configuration>
'
])
# Cleaning all variables in case you are loading the checkpoint
tf
.
reset_default_graph
()
if
os
.
path
.
exists
(
output_dir
)
else
None
logger
.
info
(
"
Directory already exists, trying to get the last checkpoint
"
)
trainer
=
config
.
Trainer
(
config
.
train_data_shuffler
,
iterations
=
0
,
analizer
=
None
,
temp_dir
=
output_dir
)
trainer
.
create_network_from_file
(
output_dir
)
import
ipdb
;
ipdb
.
set_trace
();
debug
=
True
Loading