{"id":914,"date":"2018-11-19T17:15:23","date_gmt":"2018-11-19T17:15:23","guid":{"rendered":"https:\/\/portal.supercomputing.wales\/?page_id=914"},"modified":"2018-11-19T17:15:23","modified_gmt":"2018-11-19T17:15:23","slug":"installing-python-modules","status":"publish","type":"page","link":"https:\/\/portal.supercomputing.wales\/index.php\/installing-python-modules\/","title":{"rendered":"Installing Python Modules"},"content":{"rendered":"<p>Users of Super Computing Wales don&#8217;t have permission to install libraries into system directories as might do on your own computer. Python&#8217;s pip (and pip3) package manager usually install into system directories, but have the option to install packages into your home directory by specifying the &#8211;user option. Please note that any packages you install won&#8217;t be accessible to other users and they will need to install them, themselves if they need the same modules.<\/p>\n<p>To install a Python3 module we need to do the following:<\/p>\n<p class=\"highlight\"><pre><code class=\"preserve-code-formatting\">module load python\/3.7.0\npip3 install --user &lt;modulename&gt;<\/code><\/pre><\/p>\n<p>For example to install the Sci Kit Learn module we would run:<\/p>\n<p class=\"highlight\"><code class=\"preserve-code-formatting\"> pip3 install --user sklearn<\/code><\/p>\n<p>Which would show the following output:<br \/>\n<pre class=\"\u201dhighlight\u201d preserve-code-formatting\">Collecting sklearn\n&nbsp;&nbsp;Downloading sklearn-0.0.tar.gz\nCollecting scikit-learn (from sklearn)\n&nbsp;&nbsp;Downloading scikit_learn-0.19.1-cp35-cp35m-manylinux1_x86_64.whl (12.2MB)\n&nbsp;&nbsp;&nbsp;&nbsp;100% | ************* | 12.2MB 50kB\/s \nInstalling collected packages: scikit-learn, sklearn\n&nbsp;&nbsp;Running setup.py install for sklearn ... done\nSuccessfully installed scikit-learn-0.19.1 sklearn-0.0<\/pre><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Users of Super Computing Wales don&#8217;t have permission to install libraries into system directories as might do on your own computer. Python&#8217;s pip (and pip3) package manager usually install into system directories, but have the option to install packages into your home directory by specifying the &#8211;user option. Please note that any packages you install [&hellip;]<\/p>\n","protected":false},"author":8,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_lmt_disableupdate":"","_lmt_disable":"","footnotes":""},"class_list":["post-914","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/pages\/914","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/comments?post=914"}],"version-history":[{"count":3,"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/pages\/914\/revisions"}],"predecessor-version":[{"id":917,"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/pages\/914\/revisions\/917"}],"wp:attachment":[{"href":"https:\/\/portal.supercomputing.wales\/index.php\/wp-json\/wp\/v2\/media?parent=914"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}