1.执行align_dataset_mtcnn.py出现无法导入检测模型的问题

a.现象如下

Creating networks and loading parameters
Traceback (most recent call last):
File "./src/align/align_dataset_mtcnn.py", line 146, in <module>
main(parse_arguments(sys.argv[1:]))
File "./src/align/align_dataset_mtcnn.py", line 58, in main
pnet, rnet, onet = align.detect_face.create_mtcnn(sess, None)
File "/home/xxx/eclipsews/tflearning/src/facenet/src/align/detect_face.py", line 285, in create_mtcnn
pnet.load(os.path.join(model_path, 'det1.npy'), sess)
File "/home/xxx/eclipsews/tflearning/src/facenet/src/align/detect_face.py", line 87, in load
data_dict = np.load(data_path, encoding='latin1').item() #pylint: disable=no-member
TypeError: load() got an unexpected keyword argument 'encoding'

b.原因

安装的numpython的load函数没有指定编码的参数:encoding='latin1

c.解决办法

将文件detect_face.py的87行做修改,修改如下:

data_dict = np.load(data_path, encoding='latin1').item() #pylint: disable=no-member

改为

data_dict = np.load(data_path).item() #pylint: disable=no-member

faceNet编译问题的更多相关文章

  1. 人脸识别FaceNet+TensorFlow

    一.本文目标 利用facenet源码实现从摄像头读取视频,实时检测并识别视频中的人脸.换句话说:把facenet源码中contributed目录下的real_time_face_recognition ...

  2. TODO:macOS编译PHP7.1

    TODO:macOS编译PHP7.1 本文主要介绍在macOS上编译PHP7.1,有兴趣的朋友可以去尝试一下. 1.下载PHP7.1源码,建议到PHP官网下载纯净到源码包php-7.1.0.tar.g ...

  3. Centos6.5下编译安装mysql 5.6

    一:卸载旧版本 使用下面的命令检查是否安装有MySQL Server rpm -qa | grep mysql 有的话通过下面的命令来卸载掉 rpm -e mysql //普通删除模式 rpm -e ...

  4. CENTOS 6.5 平台离线编译安装 PHP5.6.6

    一.下载php源码包 http://cn2.php.net/get/php-5.6.6.tar.gz/from/this/mirror 二.编译 编译之前可能会缺少一些必要的依赖包,加载一个本地yum ...

  5. CENTOS 6.5 平台离线编译安装 Mysql5.6.22

    一.下载源码包 http://cdn.mysql.com/archives/mysql-5.6/mysql-5.6.22.tar.gz 二.准备工作 卸载之前本机自带的MYSQL 安装 cmake,编 ...

  6. Android注解使用之注解编译android-apt如何切换到annotationProcessor

    前言: 自从EventBus 3.x发布之后其通过注解预编译的方式解决了之前通过反射机制所引起的性能效率问题,其中注解预编译所采用的的就是android-apt的方式,不过最近Apt工具的作者宣布了不 ...

  7. Hawk 6. 编译和扩展开发

    Hawk是开源项目,因此任何人都可以为其贡献代码.作者也非常欢迎使用者能够扩展出更有用的插件. 编译 编译需要Visual Stuido,版本建议使用2015, 2010及以上没有经过测试,但应该可以 ...

  8. android studio 使用 jni 编译 opencv 完整实例 之 图像边缘检测!从此在andrid中自由使用 图像匹配、识别、检测

    目录: 1,过程感慨: 2,运行环境: 3,准备工作: 4,编译 .so 5,遇到的关键问题及其解决方法 6,实现效果截图. (原创:转载声明出处:http://www.cnblogs.com/lin ...

  9. 在Windows上编译和调试CoreCLR

    生成CoreCLR - Windows篇 本文的唯一目的就是让你运行Hello World 运行环境 Window 7+ Visual studio 2015 确保C++ 工具已经被安装,默认是不安装 ...

随机推荐

  1. 2->集群架构主机优化流程

    集群架构优化流程: 有道笔记分享链接

  2. Go 1 Release Notes

    Go 1 Release Notes Introduction to Go 1 Changes to the language Append Close Composite literals Goro ...

  3. maven scope 'provided' 和 ‘compile’的区别

    解释 其实这个问题很简单. 对于scope=compile的情况(默认scope),也就是说这个项目在编译,测试,运行阶段都需要这个artifact(模块)对应的jar包在classpath中. 而对 ...

  4. SNMP相关命令

    SNMP的相关命令使用方法: snmpdelta 一直监视SNMP变量中的变化 linux:~ # snmpdelta -c public -v 1 -Cs -CT localhost IF-MIB: ...

  5. python基础学习之路No.2 数据类型

    python中常见的数据类型有:整数.浮点数.字符串.列表.元组.字典 python相较其他语言,可以省略了声明,可以直接定义赋值使用. 例如: a=12 就相当于 其他语言中的  int a=12  ...

  6. 洛谷P2279消防局的设立

    传送门啦 一个很摸不清头脑的树形dp 状态: $ dp[i][0] $ :选自己 $ dp[i][1] $ :选了至少一个儿子 $ dp[i][2] $ :选了至少一个孙子 ------------- ...

  7. elasticsearch5.5

    1.不能以root用户运行 groupadd es          #增加es组 useradd es -g es -p pwd          #增加es用户并附加到es组 chown -R e ...

  8. 2017 MoveIt!更新 ros indigo

    First MoveIt! Update in 2017. Using it on NEXTAGE pt.1 2017 MoveIt! update pt.2; Stopping motion on ...

  9. Android Activity、Service、BroadcastReceiver 的生命周期

    Activity.Service.BroadcastReceiver这三个组建是Android开发中最常使用到的组件,在它们的生命周期的各个阶段我们需要针对性的做些事情,了解这些组件的生命周期有利于我 ...

  10. USACO 5.4 Character Recognition

    Character Recognition This problem requires you to write a program that performs character recogniti ...