1.Installing Torch

参考官网:http://torch.ch/docs/getting-started.html

git clone https://github.com/torch/distro.git ~/torch --recursive
cd ~/torch; bash install-deps;
./install.sh #
The first script installs the basic package dependencies that LuaJIT and Torch require.
The second script installs LuaJIT, LuaRocks,
and then uses LuaRocks (the lua package manager) to install core packages like torch, nn and paths, as well as a few other packages
#
# On Linux with bash
source ~/.bashrc
# On Linux with zsh
source ~/.zshrc
# On OSX or in Linux with none of the above.
source ~/.profile #
The script adds torch to your PATH variable. You just have to source it once to refresh your env variables. The installation script will detect what is your current shell and modify the path in the correct configuration file.
#
$ luarocks install image
$ luarocks list #
New packages can be installed using Luarocks from the command-line:
#

  >>>th  使用该命令启动torch

     使用os.exit()退出touch 或者CTRL + C

  当测试的时候, 想引入lena的图像就会出错。解决办法:sudo apt-get install ipython-notebook

  输入如下三个命令:

    >require "image" 
    >i = image.lena() 
    >image.display(i)

  If you want to display images with th, you should use other display utilities such as gfx.go
Or, you can use qlua.

  解决办法为使用qlua开启torch:

2.Torch中的seq2seq

  https://github.com/macournoyer/neuralconvo

cpu + gpu 环境,运行:

   th -i eval.lua

出现unknown Torch class <torch.CudaTensor>

用: th -i eval.lua --cuda

  

- movie_lines.txt
    - contains the actual text of each utterance
    - fields:
        - lineID    
        行号ID
        - characterID (who uttered this phrase)
        角色ID
        - movieID
        电影
        - character name
        角色名
        - text of the utterance
        对话的文本
- movie_conversations.txt
    - the structure of the conversations
    - fields
        - characterID of the first character involved in the conversation
        对话中第一个角色ID
        - characterID of the second character involved in the conversation
        对话中第二个角色ID        
        - movieID of the movie in which the conversation occurred
        对话对应的电影ID        
        - list of the utterances that make the conversation, in chronological
        按时间顺序对话文本
            order: ['lineID1','lineID2',É,'lineIDN']
            has to be matched with movie_lines.txt to reconstruct the actual content

https://github.com/nicolas-ivanov/debug_seq2seq

ubuntu下neural-style-master的demo的更多相关文章

  1. Ubuntu下跑通py-faster-rcnn、详解demo运作流程

    在不同的服务器不同的机器上做过很多次实验,分别遇到各种不一样的错误并且跑通Py-Faster-RCNN,因此,在这里做一个流程的汇总: 一.下载文件: 首先,文件的下载可以有两种途径: 1.需要在官网 ...

  2. Ubuntu下安装gsoap

    昨天在ubuntu下进行安装gSOAP,费了很多时间,没成功,今天又来找了大量教程资料,终于一次成功,这里写下自己的安装步骤和方法,供大家参考. 首先下载gsoap,我下载的是gsoap-2.8.1. ...

  3. 在Ubuntu下搭建Spark群集

    在前一篇文章中,我们已经搭建好了Hadoop的群集,接下来,我们就是需要基于这个Hadoop群集,搭建Spark的群集.由于前面已经做了大量的工作,所以接下来搭建Spark会简单很多. 首先打开三个虚 ...

  4. Ubuntu下git的安装与使用

    Ubuntu下git的安装与使用 Ubuntu下git的安装与使用与Windows下的大致相同,只不过个人感觉在Ubuntu下使用git更方便. 首先,确认你的系统是否已安装git,可以通过git指令 ...

  5. ubuntu 下安装 texlive 并设置 ctex 中文套装

    1 安装 texlive2013 1.1 下载 texlive2013 下载地址:http://ftp.ctex.org/mirrors/CTAN/systems/texlive/Images/tex ...

  6. 初学者在ubuntu下安装使用git(下)

    4.将代码传到oschina上去 之前已经将git配置完成了,现在通过ssh的方式访问资源库,先要用命令 ssh-keygen –C '你的邮箱' –t rsa .这样就会在ssh文件夹下建一相应的密 ...

  7. ubuntu下git安装及使用

    ubuntu下git安装及使用   其实,好几个月前,就已经安装好了,可是一直搁置在那儿,所以密码等一些其它细节都忘的差不多了,所以今天就重新部署了一下,并开始积极使用......... 1,git ...

  8. ubuntu下在apache部署python站点

    ubuntu下在apache部署python站点 我的是ubuntu14 32为的虚拟机,默认安装的python为3.4 环境:apache + mysql + django + python3 软件 ...

  9. Ubuntu下使用Git和GitHub

    刚刚学习git和github,网上的知识太杂太乱.照着折腾了很长的时间,都没有搞出个结果,心里十分痒痒,最后终于在github上看到成果.本文适合刚刚接触github但是急于想看到效果的同学,当然gi ...

  10. ffmpeg2.2在ubuntu下使用NDK编译——并在android工程下测试使用

    作者:wainiwann 出处:http://www.cnblogs.com/wainiwann/ 本文版权归作者所有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则 ...

随机推荐

  1. python 文件操作总结

    Python 文件I/O 本章只讲述所有基本的的I/O函数,更多函数请参考Python标准文档. 打印到屏幕 最简单的输出方法是用print语句,你可以给它传递零个或多个用逗号隔开的表达式.此函数把你 ...

  2. [工作bug]c:import参数传递问题解析

    一.起因: 在项目的工厂中,由于某个界面根据产品种类显示的产品属性均不相同,所以决定将界面进行拆分,将每一个产品写入一个jsp界面,分别命名为product0.jsp.product1.jsp,在主界 ...

  3. 解决Genymotion无法创建新设备或无法显示设备列表问题

    准备工作: 链接: https://pan.baidu.com/s/1i5v4IBN 密码: jc3m 用2.8的和最新VirtualBox-5.1.10-112026-Win 注意事项: 1.笔记本 ...

  4. Guacamole 介绍以及架构

    Guacamole的介绍以及架构 guacd Web应用程序 在Guacamole中与用户打交道的就是Web应用程序. 之前说过,Web应用程序自己不实现任何的远程桌面协议.Web应用程序依赖guac ...

  5. three.js 显示一条线

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  6. Codeforces 567C Geometric Progression(思路)

    题目大概说给一个整数序列,问里面有几个包含三个数字的子序列ai,aj,ak,满足ai*k*k=aj*k=ak. 感觉很多种做法的样子,我想到这么一种: 枚举中间的aj,看它左边有多少个aj/k右边有多 ...

  7. myeclipse操作记录

    myeclipse里面jsp页面里面js注释快捷键 ctrl + shift +cctrl + / MyEclipse 每次保存都要building workspace的解决方法 方法一:菜单栏-&g ...

  8. 编程思想┊从实例谈面向对象编程(OOP)、工厂模式和重构

    有了翅膀才能飞,欠缺灵活的代码就象冻坏了翅膀的鸟儿.不能飞翔,就少了几许灵动的气韵.我们需要给代码带去温暖的阳光,让僵冷的翅膀重新飞起来.结合实例,通过应用OOP.设计模式和重构,你会看到代码是怎样一 ...

  9. Node.js 手册查询-5-Ejs 方法

    express 中使用 //设置模板目录 app.set('views', path.join(__dirname, 'views')); //设置模板引擎 app.set('view engine' ...

  10. UVa 11082 & 最大流的行列模型

    题意: 给出一个矩阵前i行的和与前j列的和,(i∈[1,r],j属于[1,c]),每个元素ai,j∈[1,20],请你还原出这个矩阵,保证有解. SOL: 给网络流建模跪了,神一样的建图,如果我我会怎 ...