【问题标题】:How to install Openface in windows python如何在 windows python 中安装 Openface
【发布时间】:2016-10-27 12:22:22
【问题描述】:

我是 Openface 的新手。由于某些原因,我想用 python 在 windows 中安装 Openface。如果有人能指导我完成那将是很棒的。我在网上搜索过,但没有一篇关于windows python安装的文章。可能是我在问一个非常简单的问题,但请帮助我解决这个问题。

【问题讨论】:

    标签: python windows installation deep-learning face-recognition


    【解决方案1】:

    我不知道 OpenFace 是否直接在 Windows 上使用,但如果您开始处理此问题,请为存储库提供任何必要的更改。我预计只有 Linux 的功能会存在一些兼容性问题。

    解决方法是在 Windows 上使用 Docker 机器预构建 OpenFace Docker 容器。其中一些来自OpenFace setup guide。首先start a Linux Docker machine on Windows。然后从here拉取OpenFace docker容器:

    docker pull bamos/openface
    docker run -p 9000:9000 -p 8000:8000 -t -i bamos/openface /bin/bash
    cd /root/openface
    ./demos/compare.py images/examples/{lennon*,clapton*}
    ./demos/classifier.py infer models/openface/celeb-classifier.nn4.small2.v1.pkl ./images/examples/carell.jpg
    ./demos/web/start-servers.sh
    

    【讨论】:

    • 我认为这是唯一的方法。无法在 windows 上安装,只能使用 docker。
    【解决方案2】:

    在适合我的 Windows 中安装 openface 的步骤。

    1. 从此路径下载openface-http://cmusatyalab.github.io/openface/
    2. 将openface文件夹粘贴到python.exe文件所在的路径中。
    3. 运行命令 python openface/setup.py install

    【讨论】:

    • 不要相信这行得通。你真的运行了一个 openface 应用程序并看到它工作了吗?
    【解决方案3】:

    如果您使用的是 anaconda,那么以下步骤对我有用。这些步骤的功劳归于 nitish11,他在 github 上发布了这些步骤:https://gist.github.com/ageitgey/82d0ea0fdb56dc93cb9b716e7ceb364b

    1. 从 anaconda 中打开命令行。
    2. 如果需要,安装 git (conda install -c anaconda git)
    3. git clone https://github.com/cmusatyalab/openface.git
    4. cd openface
    5. pip install -r requirements.txt
    6. (sudo) python setup.py install

    sudo 在步骤 6 中可能不需要。

    希望这会有所帮助。

    【讨论】:

      猜你喜欢
      • 2016-06-18
      • 1970-01-01
      • 2014-10-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-01-16
      • 2010-10-27
      • 2021-05-28
      相关资源
      最近更新 更多