分享一款有趣的工具——neural-style

neural-style是一款使用机器学习给照片添加各种风格的Python工具,详细介绍可以参考https://github.com/anishathalye/neural-style

  1. 安装Python3;

  2. 从Github克隆代码;

    1
    git clone https://github.com/anishathalye/neural-style
  3. 安装需求的包numpyPillowscipytensorflow

    1
    pip install -r requirements.txt
  4. 下载训练好的模型放在neural-style的根目录;

    Pre-trained VGG network (MD5 106118b7cf60435e6d8e04f6a6dc3657)

  5. 运行;

    1
    python neural_style.py --content <content file> --styles <style file> --output <output file>
阅读更多