轉載請注明出處:
http://www.cnblogs.com/darkknightzh/p/6424398.html
參考網址:
https://github.com/torch/nn/issues/974
https://github.com/brotchie/torch-ubuntu-gpu-ec2-install/issues/4
https://github.com/torch/cunn/issues/388
1. 更新nn
如果torch的某個模塊需要更新的話,可以直接使用luarocks install moduleName進行重新安裝。但是在更新nn時,提示
“unknown type name ptrdiff_t”
兩個參考網址中均碰到了這個問題。
第一個參考網址最后說,先重新安裝torch,在安裝需要的模塊。試了一下,成功了。
luarocks install torch
而后:
luarocks install nn
=====================================================================
170227更新:
2. 更新cunn
直接使用luarocks install cunn,提示下面的問題:
THCGenerateFloatTypes.h: No such file or directory
如參考網址3所示。該網址也提供了解決方法:需要重新安裝cutorch(luarocks install cutorch),之后再安裝cunn(luarocks install cunn)就可以了。
說明:其實剛才碰到了一個很詭異的問題,重新安裝cutorch后,第一次安裝cunn時失敗了,第二次輸入同樣的命令,就成功了。。。
170227更新結束
170804更新:
如果在電腦使用了anaconda2后,安裝torch,可能會提示:anaconda2/lib/libcurl.so.4: no version information available.
https://github.com/torch/torch7/issues/629中guopzhao指出,可以把anaconda2重命名一下,然后使用luarocks install torch來安裝torch,之后再把anaconda2名字改回來就可以了。
170804更新結束
=====================================================================