Torch: Difference between revisions
(mark for translation) |
(Marked this version for translation) |
||
Line 2: | Line 2: | ||
<translate> | <translate> | ||
<!--T:1--> | |||
[[Category:Software]] | [[Category:Software]] | ||
"[http://torch.ch/ Torch] is a scientific computing framework with wide support for machine learning algorithms that puts GPUs first. It is easy to use and efficient, thanks to an easy and fast scripting language, LuaJIT, and an underlying C/CUDA implementation." | "[http://torch.ch/ Torch] is a scientific computing framework with wide support for machine learning algorithms that puts GPUs first. It is easy to use and efficient, thanks to an easy and fast scripting language, LuaJIT, and an underlying C/CUDA implementation." | ||
<!--T:2--> | |||
Torch has a distant relationship to PyTorch.<ref>See https://stackoverflow.com/questions/44371560/what-is-the-relationship-between-pytorch-and-torch, https://www.quora.com/What-are-the-differences-between-Torch-and-Pytorch, and https://discuss.pytorch.org/t/torch-autograd-vs-pytorch-autograd/1671/4 for some attempts to explain the connection.</ref> PyTorch provides a [[Python]] interface to similar capabilities, but one is not directly dependent on the other. See [[PyTorch]] for instructions on using it. | Torch has a distant relationship to PyTorch.<ref>See https://stackoverflow.com/questions/44371560/what-is-the-relationship-between-pytorch-and-torch, https://www.quora.com/What-are-the-differences-between-Torch-and-Pytorch, and https://discuss.pytorch.org/t/torch-autograd-vs-pytorch-autograd/1671/4 for some attempts to explain the connection.</ref> PyTorch provides a [[Python]] interface to similar capabilities, but one is not directly dependent on the other. See [[PyTorch]] for instructions on using it. | ||
<!--T:3--> | |||
Torch depends on [[CUDA]]. In order to use Torch you must first load a CUDA module, like so: | Torch depends on [[CUDA]]. In order to use Torch you must first load a CUDA module, like so: | ||
<!--T:4--> | |||
{{Command|module load cuda torch}} | {{Command|module load cuda torch}} | ||
== Installing Lua packages == | == Installing Lua packages == <!--T:5--> | ||
Torch comes with the Lua package manager, named [https://luarocks.org/ luarocks]. By design, <tt>luarocks</tt> will allow you to install new packages, but will not find the system packages. To install packages in your own folder, use the following: | Torch comes with the Lua package manager, named [https://luarocks.org/ luarocks]. By design, <tt>luarocks</tt> will allow you to install new packages, but will not find the system packages. To install packages in your own folder, use the following: | ||
<!--T:6--> | |||
{{Command|luarocks install --local --deps-mode{{=}}all <package name>}} | {{Command|luarocks install --local --deps-mode{{=}}all <package name>}} | ||
<!--T:7--> | |||
By experience, we often find packages that do not install well with <tt>luarocks</tt>. If you have a package that is not installed in the default module and need help installing it, please contact our [[Technical support]]. | By experience, we often find packages that do not install well with <tt>luarocks</tt>. If you have a package that is not installed in the default module and need help installing it, please contact our [[Technical support]]. | ||
<!--T:8--> | |||
<references /> | <references /> | ||
</translate> | </translate> |
Revision as of 18:53, 28 March 2018
"Torch is a scientific computing framework with wide support for machine learning algorithms that puts GPUs first. It is easy to use and efficient, thanks to an easy and fast scripting language, LuaJIT, and an underlying C/CUDA implementation."
Torch has a distant relationship to PyTorch.[1] PyTorch provides a Python interface to similar capabilities, but one is not directly dependent on the other. See PyTorch for instructions on using it.
Torch depends on CUDA. In order to use Torch you must first load a CUDA module, like so:
[name@server ~]$ module load cuda torch
Installing Lua packages
Torch comes with the Lua package manager, named luarocks. By design, luarocks will allow you to install new packages, but will not find the system packages. To install packages in your own folder, use the following:
[name@server ~]$ luarocks install --local --deps-mode=all <package name>
By experience, we often find packages that do not install well with luarocks. If you have a package that is not installed in the default module and need help installing it, please contact our Technical support.