You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
798 B
41 lines
798 B
2 years ago
|
"""
|
||
|
Programmer : EOF
|
||
|
File : training.py
|
||
|
Date : 2015.12.29
|
||
|
E-mail : jasonleaster@163.com
|
||
|
|
||
|
"""
|
||
|
|
||
|
from config import TRAINING_FACE
|
||
|
from config import TRAINING_NONFACE
|
||
|
from config import CASACADE_LIMIT
|
||
|
|
||
|
from cascade import Cascade
|
||
|
|
||
|
from time import time
|
||
|
|
||
|
from multiprocessing import freeze_support
|
||
|
|
||
|
raise Exception("Unimplemented Cascade")
|
||
|
|
||
|
if __name__ == "__main__":
|
||
|
freeze_support()
|
||
|
|
||
|
start_time = time()
|
||
|
model = Cascade(TRAINING_FACE, TRAINING_NONFACE, limit = CASACADE_LIMIT)
|
||
|
end_time = time()
|
||
|
|
||
|
print "total Cost time: ", end_time - start_time
|
||
|
|
||
|
try:
|
||
|
model.train()
|
||
|
model.save()
|
||
|
except KeyboardInterrupt:
|
||
|
print "key board interrupt happened. training pause."
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|