Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
py-3d-face-reconstruction
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Richard Torenvliet
py-3d-face-reconstruction
Commits
12d33735
Commit
12d33735
authored
Nov 14, 2016
by
Richard Torenvliet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Made changes for production deployment
parent
91eabca7
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
27 additions
and
19 deletions
+27
-19
.gitignore
.gitignore
+1
-0
actions.mk
actions.mk
+6
-6
makefile
makefile
+18
-12
src/reconstruction/build.mk
src/reconstruction/build.mk
+1
-0
src/server.py
src/server.py
+1
-1
No files found.
.gitignore
View file @
12d33735
...
...
@@ -7,3 +7,4 @@ src/reconstruction/*.c
src/reconstruction/build/
*.dSYM
vendor/*
*.pyc
actions.mk
View file @
12d33735
TARGETS
+=
data/pca_shape_train_model.npy
.PHONY
:=
train_model show_pca test_model show_reconstruction
DEBUG_LEVEL
=
*
data/imm_face_db
:
data/imm_face_db.tar.gz
(
cd
data
;
mkdir
-p
imm_face_db
;
\
tar
-xvzf
imm_face_db.tar.gz
-C
imm_face_db
tar
-xvzf
imm_face_db.tar.gz
-C
imm_face_db
\
)
train_model
:
train_shape train_texture
train_texture
:
data/pca_imm_texture_model.npy data/pca_ibug_texture_model.npy
train_shape
:
data/pca_imm_shape_model.npy data/pca_ibug_shape_model.npy
shape_predictor_68_face_landmarks.dat
:
wget http://dlib.net/files/shape_predictor_68_face_landmarks.dat.bz2
-P
data/
(
cd
data/
;
bzip2
-d
shape_predictor_68_face_landmarks.dat.bz2
)
data/imm_face_db.tar.gz
:
(
cd
data
;
wget http://www.imm.dtu.dk/~aam/datasets/imm_face_db.tar.gz
)
...
...
@@ -17,7 +16,8 @@ data/imm_face_db.tar.gz:
runnit
:
$(BASE_DOCKER_CMD)
python main.py
compile_texture
:
src/reconstruction/texture.pyx
src/reconstruction/texture.so
:
src/reconstruction/texture.pyx
$(BASE_DOCKER_CMD)
/bin/bash
-c
'(cd reconstruction; python setup.py build_ext --inplace)'
data/pca_imm_shape_model.npy
:
...
...
makefile
View file @
12d33735
DEBUG
:=
1
VERSION
:=
v0.1
IMAGE_TAG
:=
icyrizard/face-reconstruction.git:
$(VERSION)
BASE_DOCKER_CMD
:=
docker run
\
--rm
\
--volume
/Users/richard/Documents/sighthub/face-reconstruction
/data:/data
\
--volume
/Users/richard/Documents/sighthub/face-reconstruction
/src:/src
\
HERE
:=
$(
shell
pwd
)
DOCKER_RUN_FLAGS
:=
--rm
\
--volume
$(HERE)
/data:/data
\
--volume
$(HERE)
/src:/src
\
-e
"DEBUG=
$(DEBUG)
"
\
-p
8888:8888
\
$(IMAGE_TAG)
-p
6930:8888
include
actions.mk
include
src/reconstruction/build.mk
BASE_DOCKER_CMD
:=
docker run
$(DOCKER_RUN_FLAGS)
$(IMAGE_TAG)
$(info
$(TARGETS))
all
:
$(TARGETS)
DEPENDENCIES
:=
data/imm_face_db
TARGETS
:=
shape_predictor_68_face_landmarks.dat
\
src/reconstruction/texture.so
\
data/pca_ibug_shape_model.npy
\
data/pca_ibug_texture_model.npy
data
:
data/imm_face_db
reconstruction
:
texture.so
all
:
$(DEPENDENCIES) $(TARGETS)
include
actions.mk
include
src/reconstruction/build.mk
OS
:=
$(
shell
uname
)
...
...
@@ -23,7 +29,7 @@ build: requirements.txt
docker build
-t
$(IMAGE_TAG)
.
run-bash
:
$(BASE_DOCKER_CMD)
--interactive
--tty
$(IMAGE_TAG)
/bin/bash
docker run
--interactive
--tty
$(DOCKER_RUN_FLAGS)
$(IMAGE_TAG)
/bin/bash
$(VIRTUALENV)
:
virtualenv
-p
$(PYTHON_BIN_PATH)
venv
...
...
src/reconstruction/build.mk
View file @
12d33735
HERE
:=
$(
shell
pwd
)
TARGETS
+=
src/reconstruction/texture.so
ifeq
($(OS),Darwin)
HALIDE_LINK
:=
https://github.com/halide/Halide/releases/download/release_2016_04_27/halide-mac-64-trunk-2f11b9fce62f596e832907b82d87e8f75c53dd07.tgz
...
...
src/server.py
View file @
12d33735
...
...
@@ -194,7 +194,7 @@ app = web.Application([
if
__name__
==
'__main__'
:
app
.
listen
(
8888
)
app
.
listen
(
8888
,
xheaders
=
True
)
ioloop
=
ioloop
.
IOLoop
.
instance
()
autoreload
.
start
(
ioloop
)
ioloop
.
start
()
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment