File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change
1
+ SERVER = ' http://api.cn.faceplusplus.com/'
2
+ # uncomment the following line to switch to US server
3
+ # SERVER = 'http://api.us.faceplusplus.com/'
4
+
1
5
API_KEY = ' <your API key here>'
2
6
API_SECRET = ' <your API secret here>'
Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env python2
2
2
# -*- coding: utf-8 -*-
3
3
# $File: cmdtool.py
4
- # $Date: Sat Nov 17 14:14:38 2012 +0800
4
+ # $Date: Sat Apr 06 11:47:10 2013 +0800
5
5
# $Author: jiakai@megvii.com
6
6
#
7
7
# This program is free software. It comes without any warranty, to
@@ -42,8 +42,9 @@ def init():
42
42
with open (os .path .join (fdir , 'apikey.cfg' )) as f :
43
43
exec (f .read ())
44
44
45
+ srv = locals ().get ('SERVER' )
45
46
from facepp import API
46
- return API (API_KEY , API_SECRET )
47
+ return API (API_KEY , API_SECRET , srv = srv )
47
48
48
49
api = init ()
49
50
You can’t perform that action at this time.
0 commit comments