<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Andrada Vulpe on Medium]]></title>
        <description><![CDATA[Stories by Andrada Vulpe on Medium]]></description>
        <link>https://medium.com/@andradavulpe?source=rss-886fb15473d7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*11PefJfa3RQAeIryIkSJqw.jpeg</url>
            <title>Stories by Andrada Vulpe on Medium</title>
            <link>https://medium.com/@andradavulpe?source=rss-886fb15473d7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 15:07:47 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@andradavulpe/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Z by HP Data Science Software Stack — the answer to your set-up hassle]]></title>
            <link>https://andradavulpe.medium.com/z-by-hp-data-science-software-stack-the-answer-to-your-set-up-hassle-73361fc4d79e?source=rss-886fb15473d7------2</link>
            <guid isPermaLink="false">https://medium.com/p/73361fc4d79e</guid>
            <category><![CDATA[software]]></category>
            <category><![CDATA[z]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[workstation]]></category>
            <dc:creator><![CDATA[Andrada Vulpe]]></dc:creator>
            <pubDate>Thu, 22 Apr 2021 08:12:45 GMT</pubDate>
            <atom:updated>2021-04-22T08:12:45.911Z</atom:updated>
            <content:encoded><![CDATA[<h3>Z by HP Data Science Software Stack — the answer to your set-up hassle</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*kQYNw1Dah0D7oA21" /><figcaption>Photo by <a href="https://unsplash.com/@galex?utm_source=medium&amp;utm_medium=referral">Alex Ghizila</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>Introduction</h3><p>I wanted to do this blog post for all Data Scientists out there that <em>love</em> the science, but not the set-up part of it.</p><p>Indeed, many people like to do everything themselves, and this also includes setting up their Data Science Environment. They like installing each package one by one, check out new versions, look out for new improved options.</p><p>However, I am not one of these people. Are you?</p><p>If not, in this article I am going to present you with the Holy Grail of the Data Science Environment set-up. Why can I tell you about this? Because months on end I went through issues on setting up my perfect Data Science Environment, up to a point where I wasn’t even doing much Data Science at all, to be honest. However, I was deep into articles on CLI, Windows set up, WSL2, command errors, dependencies errors, driver incompatibilities … all that cute package and all.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/388/1*O9nKB8SEjVrZMQlITxXlgQ.png" /></figure><p>No more. The hassle is over.</p><h3>How it was</h3><p>I would like to layout a bit of the context I was in. If you aren’t interested in this part, just jump to the next chapter, where I tell you how I got rid of all my problems.</p><blockquote>I started with a Z8 G4 Workstation from HP, with some pretty powerful features I would say: a 96 GB of memory, 2 CPUs, and a sweet NVIDIA Quadro RTX 8000. This dragon was ready to train some models and process some data for sure, and I was super psyched about it.</blockquote><p>It took me around 2–3 days to properly install my usual software. Some of them were:</p><ul><li>Anaconda</li><li>PyCharm</li><li>Git</li><li>PyTorch (and many more other libraries that don’t come pre-installed with Anaconda)</li><li>XGBoost</li><li>R Studio</li><li>Nvidia CUDA</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*gt7PnaHr594JGHdtwFEsJA.jpeg" /></figure><p>Then I proceeded to install RAPIDS — how to have an NVIDIA graphics unit and NOT install RAPIDS?</p><p>And here I hit the wall, and hard I would say. RAPIDS works only on Linux and I was working on Windows 10. Hence, I proceeded to update my windows (which took a few hours), installing WSL2 and then setting up RAPIDS (<a href="https://andradaolteanu.medium.com/how-to-install-and-use-rapids-on-your-windows-workstation-a31af966ef62">for this process I did a detailed article with code here</a>). All this took a bonus of another few days. Is anybody counting?😪</p><p>However, there was an issue: mounting the container. Long story short, when closing the RAPIDS environment after your work is done everything gets purged: data, notebooks, even installed libraries. This isn’t useful when you’re trying to work on a long term project.</p><p>Then I proceeded to move to Linux; from my research, this is the OS that Data Scientists are starting to use anyways. However, setting up the environment STILL proved to be a hassle, starting aaaaaaaaaall over again, doing tests to see that everything works how it should, other super specific errors…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/327/1*ZxMDPazj9EjD8wnBp42_1A.jpeg" /></figure><p>I won’t lie: I was a bit worn out.</p><p>Then, I found out about the Z by HP Data Science Software Stack.</p><h3>The Z by HP Data Science Software Preload</h3><p>It is unreal. It is perfect. It is quick. It doesn’t require your attention. And after it’s done everything works perfectly and you can start Data Sciencin’ instantly.</p><p>As of now, the Stack is available for <a href="https://press.hp.com/us/en/blogs/2020/z-by-hp-data-science-software.html">HP Z4, HP Z6, HP Z8 desktop workstations and is planned for the end of December on the HP ZBook Studio G7 and HP ZBook Create G7</a> (but it will be extended in 2021). And … it comes with <strong>everything</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nOJT3ctggJ_cyqD5ng8yRg.png" /><figcaption><a href="https://www8.hp.com/us/en/workstations/industries/data-science.html">Image from Z by HP website</a></figcaption></figure><h4>The Data Science Software Stack comes with:</h4><ul><li>The latest Python &amp; R version</li><li>Preloaded environments like Anaconda, PyCharm, Visual Studio</li><li>GIT</li><li>Data Science packages like PyTorch, TensorFlow, XGBoost</li><li>RAPIDS: with an Anaconda environment where you can easily switch between base and rapids</li><li>Docker Container and Nvidia Drivers</li><li>etc.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JtvDr46RUIG1NJE0CiXeXQ.png" /><figcaption>Image from <a href="https://press.hp.com/us/en/blogs/2020/z-by-hp-data-science-software.html">Z by HP Press Center</a></figcaption></figure><p>And the best part? It comes with the gear.</p><p>Yup.</p><p>The Software Preload comes already installed with the laptops and desktops mentioned above. So you don’t have to do anything more.</p><blockquote>As they say on their website, get a “plug-and-play” experience, instantly! Productivity from day 1 indeed!</blockquote><h3>More References</h3><p>For more information on the preload, you could follow one of the following links:</p><ul><li><a href="https://store.hp.com/us/en/tech-takes/z-by-hp-data-science-software">Z by HP Data Science Software Solution: A Complete Overview</a></li><li><a href="https://www8.hp.com/us/en/workstations/industries/data-science.html">Introducing our new Data Science Solution</a></li><li><a href="https://press.hp.com/us/en/blogs/2020/z-by-hp-data-science-software.html">Simplifying the Data Science Workflow with Z by HP’s Data Science Software Solution</a></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gutxlUPk4gRctEGmKUS5Ug.png" /></figure><blockquote>Happy Data Sciencin’!</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=73361fc4d79e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Install and Use RAPIDS on your Windows Workstation]]></title>
            <link>https://andradavulpe.medium.com/how-to-install-and-use-rapids-on-your-windows-workstation-a31af966ef62?source=rss-886fb15473d7------2</link>
            <guid isPermaLink="false">https://medium.com/p/a31af966ef62</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[rapids-ai]]></category>
            <category><![CDATA[windows-10]]></category>
            <category><![CDATA[workstation]]></category>
            <category><![CDATA[wsl-2]]></category>
            <dc:creator><![CDATA[Andrada Vulpe]]></dc:creator>
            <pubDate>Mon, 14 Dec 2020 18:46:44 GMT</pubDate>
            <atom:updated>2020-12-15T13:16:33.568Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*rhm85F1Udx5NZraF" /><figcaption>Photo by <a href="https://unsplash.com/@loganmayerr?utm_source=medium&amp;utm_medium=referral">Logan Mayer</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>I have been having troubles finding a good <strong>end-to-end</strong> article that could help me install and teach me how to use RAPIDS on my Windows Workstation.</p><p>At the moment, <a href="https://rapids.ai/">RAPIDS</a> has as prerequisite that you have to be running the Ubuntu or CentOS Operating Systems on your Workstation to be able to use it (more about prerequisites <a href="https://rapids.ai/start.html">here</a>).</p><p>This wasn’t my case. I had a <em>Windows 10 Pro</em> running on my computer, and I hit the wall hard when I realized there’s little to no documentation on the internet on how to properly install RAPIDS if you have Windows. Of course, there are references, but I am more oriented towards the data science area than the technical areas — hence, I struggled a bit until I found the solution.</p><p>I am making this article in the hopes that it would help anybody that is in the same situation as I was when I started. I will also explain the concepts to the best of my ability, so you won’t follow the guidelines mindlessly, but also understand what you’re doing.</p><p>As a reference, I have a <strong>HP Z8 Workstation</strong> with an <strong>NVIDIA Quadro RTX 8000</strong>, and a Windows 10 Pro for Workstations.</p><p>I would also like to add some very special thanks to my partner, who is much more technical than me and has been kind enough to help and guide me throughout this journey.</p><p>Ok, let’s dive in! (as a PS: this <em>process might take a few hours and up to one day</em>, so be patient and take some time to do it)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AUmNowl1POr7KwzL60eLbA.png" /></figure><h3>1. Getting Started</h3><p><a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">This is one of the main articles you’ll be following: Cuda on WSL.</a> I encourange you to <strong>open the link and follow it with this article side by side</strong>, as there are some little tweaks and perks that I did that you might also need.</p><p>So, how are you going to use Ubuntu, if you have Windows. Here is where <strong>WSL 2</strong> comes into action(you want to use “2”, not the first version).</p><blockquote>WSL is a containerized environment within which users can run Linux native applications from the command line of the Windows 10 shell <strong>without requiring the complexity of a dual boot environment</strong>.</blockquote><p>WSL is short from “Windows Subsystem for Linux” and it’s a pretty great method of installing Linux on your machine without having a VDI (Virtual Desktop Environment, which creates a computer on your computer), or without having to dual boot (which comes with the effort of having to switch between your operating systems, having to download on both any required packages, applications etc.)</p><p>So, in the “Getting Started” chapter of the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">Cuda on WSL</a> tutorial you are required to:</p><ul><li><strong>Install Microsoft Windows Insider Program Builds</strong>: Here you make sure that you have your Windows OS up and ready for what’s coming, so you won’t have any weird unexpected errors later in the process. You’ll have to register and do the steps in the “2. Flight” section (this might take a few hours). After you’re finished, be sure you check your build version by pressing “Windows” + R and write winver in the console. Your build should be greater than 20145.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AWzltolr6jOH659mTvN87A.png" /><figcaption>Windows Program Builds</figcaption></figure><ul><li><strong>Installing the NVIDIA Drivers:</strong> The NVIDIA driver is a software application that you will have to install on your workstation. It enables the communication between Windows and the <em>NVIDIA Graphics GPU</em>. You’ll have to make a free account on the <a href="https://developer.nvidia.com/">NVIDIA Developer</a> website and follow the steps in the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> to download and run the executable (either QUADRO or GEFORCE, depending on you NVIDIA GPU).</li><li><strong>Installing WSL 2: </strong>This is the last step in this section. You’ll need to install WSL 2 from <a href="https://docs.microsoft.com/en-gb/windows/wsl/install-win10">this article</a> in the “Manual Installation Steps” section. At <em>Step 6</em>, I chose to install the “Ubuntu 20.04 LTS” Linux Distribution. Another thing I would recommend is installing the <em>Windows Terminal</em> from the Store (it provides an interface where you can use multiple terminals like Ubuntu, Wondows Power Shell etc. without the need to change between them all the time). To check your WSL version, write in the Windows Power Shell : wsl cat /proc/version .</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ArVPDJYoTA8E41iX-Zrc4Q.png" /><figcaption>Check your WSL version</figcaption></figure><h3>2. Setting up the CUDA Toolkit</h3><blockquote>The NVIDIA® CUDA® Toolkit provides a development environment for creating high performance GPU-accelerated applications. The toolkit includes GPU-accelerated libraries, debugging and optimization tools, a C/C++ compiler, and a runtime library to build and deploy your application on major architectures including x86, Arm and POWER. More <a href="https://developer.nvidia.com/cuda-toolkit#:~:text=The%20toolkit%20includes%20GPU%2Daccelerated,including%20x86%2C%20Arm%20and%20POWER.">here</a>.</blockquote><p>In the same <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> which we used to prepare the stage and get our workstation ready to use, we have the “<em>Setting up CUDA Toolkit</em>” chapter. The commands shown in the tutorial will be wrote from now on in the <em>Ubuntu Command Prompt:</em></p><ul><li><strong>Setting up the CUDA network repository: </strong>Commands are exactly as they are shown in the tutorial; however, if a “<em>Permission denied</em>” error ocures, you might want to add sudo at the beginning of each line, like this:</li></ul><pre>sudo apt-key adv --fetch-keys <a href="http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/7fa2af80.pub">http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/7fa2af80.pub</a></pre><pre>sudo sh -c &#39;echo &quot;deb <a href="http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64">http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64</a> /&quot; &gt; /etc/apt/sources.list.d/cuda.list&#39;</pre><pre>sudo apt-get update</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3l6UvqPYyD6MQcXpC4f_ZQ.png" /></figure><ul><li><strong>Installing CUDA:</strong> This process might take a bit longer, so you can go grab yourself a beverage until it finishes. Again, I used sudo at the beginning of the command, but the rest is the same as in the tutorial.</li></ul><pre>sudo apt-get install -y cuda-toolkit-11-0</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Q81AyIKdx0u49cNCMsS0HQ.png" /></figure><h3>3. Running CUDA Applications</h3><p>The next chapter in the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> is “<em>Running CUDA Applications</em>”. Here, the alternative method they are providing to build the CUDA samples didn’t work for me. So, I encourage you to:</p><ul><li>First go in the usr/local/cuda/samples/4_Finance/BlackScholes folder (as shown below).</li></ul><pre>cd /usr/local/cuda/samples/4_Finance/BlackScholes</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-miqkxqWY9HdeOVQSgr3vQ.png" /></figure><ul><li>Run sudo make and then rellocate your path wherever the output shows you to go (in the example, the path is highlighted in orange).</li></ul><pre>sudo make</pre><pre>cd ../../bin/x86_64/linux/release/</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Je_13xFjGuoJWMXyZXKmUg.png" /></figure><ul><li>Run the ./BlackScholes command. It will initialize and execute the GPU Kernel. Once is done, it will prompt “test passed” like in the image below.</li></ul><pre>./BlackScholes</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HUeC_MsLJB3KkQZkCYaLzw.png" /><figcaption>Test Passed</figcaption></figure><h3>4. Setting up the Run Containers</h3><blockquote><strong>Containers</strong> are a form of operating system virtualization. A single <strong>container</strong> might be used to run anything from a small microservice or software process to a larger application. Inside a <strong>container</strong> are all the necessary executables, binary code, libraries, and configuration files.</blockquote><p>Here we’ll be using <em>Docker Containers </em>— meaning we need to first install a Docker that will carry all the Containers. This will enable us further to run RAPIDS, install other Data Science Libraries or create Jupyter Notebooks — all safely available in the Container.</p><h4><strong>4.1 Installing the Docker</strong></h4><p>Installing the Docker was harder and required more attention than I thought. In the tutorial, in the “<em>Setting up to Run Containers</em>” chapter, in the “<em>Install Docker</em>” subsection, the command looked simple:</p><pre>curl https://get.docker.com | sh       # ERROR</pre><p>But for me it threw an error:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RQ9UMzOFM2WEIYGnImjEcQ.png" /><figcaption>error thrown</figcaption></figure><p>It says that the recommendation would be to use Docker Desktop for Windows; however, the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> states clearly that the <em>NVIDIA Container Toolkit</em> <em>doesn’t support</em> <em>the Desktop Docker at the moment</em>. Hence, I had to run manually the orange commands, which themselves were having errors as well (they were missing some important “ ‘ ”). Below is a snippet of the initial commands and the corrected version (so use these instead):</p><pre># === INITIAL (do not recommend) ===</pre><pre>sudo -E sh -c apt-get update -qq &gt;/dev/null<br>sudo -E sh -c DEBIAN_FRONTEND=noninteractive apt-get install -y -qq apt-transport-https ca-certificates curl &gt;/dev/null<br>sudo -E sh -c curl -fsSL &quot;<a href="https://download.docker.com/linux/ubuntu/gpg">https://download.docker.com/linux/ubuntu/gpg</a>&quot; | apt-key add -qq - &gt;/dev/null<br>sudo -E sh -c echo &quot;deb [arch=amd64] <a href="https://download.docker.com/linux/ubuntu">https://download.docker.com/linux/ubuntu</a> focal stable&quot; &gt; /etc/apt/sources.list.d/docker.list<br>sudo -E sh -c apt-get update -qq &gt;/dev/null<br>sudo -E sh -c apt-get install -y -qq --no-install-recommends docker-ce &gt;/dev/null<br></pre><pre># === HOW IT SHOULD BE ===<br><br>sudo -E sh -c &#39;apt-get update -qq&#39; &gt;/dev/null<br>sudo -E sh -c &#39;DEBIAN_FRONTEND=noninteractive apt-get install -y -qq apt-transport-https ca-certificates curl&#39; &gt;/dev/null<br>sudo -E sh -c &#39;curl -fsSL &quot;<a href="https://download.docker.com/linux/ubuntu/gpg">https://download.docker.com/linux/ubuntu/gpg</a>&quot; | apt-key add -qq -&#39;<br>sudo -E sh -c &#39;echo &quot;deb [arch=amd64] <a href="https://download.docker.com/linux/ubuntu">https://download.docker.com/linux/ubuntu</a> focal stable&quot; &gt; /etc/apt/sources.list.d/docker.list&#39;<br>sudo -E sh -c &#39;apt-get update -qq&#39; &gt;/dev/null<br>sudo -E sh -c &#39;apt-get install -y -qq --no-install-recommends docker-ce&#39; &gt;/dev/null</pre><h4><strong>4.2 Installing the NVIDIA Container Toolkit</strong></h4><blockquote>The <strong>NVIDIA Container Toolkit</strong> allows users to build and run <strong>GPU</strong> accelerated Docker containers. The toolkit includes a container runtime library and utilities to automatically configure containers to leverage NVIDIA GPUs.</blockquote><p>This part was again the same process as described in the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> in the “<em>Install NVIDIA Container Toolkit</em>”.</p><pre>distribution=$(. /etc/os-release;echo $ID$VERSION_ID)<br><br>curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add -<br><br>curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | sudo tee /etc/apt/sources.list.d/nvidia-docker.list<br><br>curl -s -L https://nvidia.github.io/libnvidia-container/experimental/$distribution/libnvidia-container-experimental.list | sudo tee /etc/apt/sources.list.d/libnvidia-container-experimental.list</pre><pre>sudo apt-get update<br><br>sudo apt-get install -y nvidia-docker2</pre><pre>sudo service docker stop<br><br>sudo service docker start</pre><h3>5. Run CUDA Containers</h3><h4>5.1 Simple CUDA containers</h4><p>As shown in the tutorial, just run the following command:</p><pre>sudo docker run --gpus all nvcr.io/nvidia/k8s/cuda-sample:nbody nbody -gpu -benchmark</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UkwZCYQMPMuPVjHewX9LCg.png" /></figure><h4>5.2 Jupyter Notebook</h4><p>We’re finally getting closer to the Data Science. In the same Ubuntu terminal you’ve been writing commands so far, just run the command in the “<em>Jupyter Notebooks</em>” subsection in the <a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">tutorial</a> . You should afterwards see something like this:</p><pre>sudo docker run -it --gpus all -p 8888:8888 tensorflow/tensorflow:latest-gpu-py3-jupyter</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Mh_AHiKFGv7B8TLspnlEvg.png" /><figcaption>jupyter notebook installation</figcaption></figure><h3>6. Installing RAPIDS</h3><p><strong>RAPIDS </strong>has on their website a <a href="https://rapids.ai/start.html">Get Started</a> section from where you can copy the necessary comand to <em>install</em> RAPIDS. Just select the preferred method and copy the 2 commands in the terminal (<em>be weary of the path — I am now in /mnt/c/Users/andrada</em>):</p><pre>sudo docker pull rapidsai/rapidsai:cuda10.1-runtime-ubuntu18.04</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QcuAn1yXLuMLuE_Y_pOJQQ.png" /></figure><pre>sudo docker run --gpus all --rm -it -p 8888:8888 -p 8787:8787 -p 8786:8786 \<br>     rapidsai/rapidsai:cuda10.1-runtime-ubuntu18.04</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LkoUle84Ra2l2rDQfkLZ4w.png" /></figure><p>Now, as you can see in <strong>orange</strong>, a JupyterLab server has been started, with the <em>localhost:8888</em>. However, besides the fact that the above command is long and hard to remember, this method would <em>never manage to keep what you create</em> (notebooks, files etc.) after you end the current session. The container is going to <strong>purge </strong>any information once you close it (not very practical, huh?).</p><p>There is a way though that can help ease both the access to the container and keep the files you create even after closing. You’ll have to make your local folders visible by <em>mounting </em>to <strong>/rapids/notebooks/host</strong>. To do that, go ahead and create a path like that wherever you would like on your computer (in my case, I created a main folder names <strong>9. RAPIDS</strong> in which I created an empty <strong>notebooks </strong>folder).</p><p>Hence, what we’ll do is create a <em>.sh</em> file in the <strong>9. RAPIDS</strong> folder (or however you called yours). Then enter in the path and write the following:</p><pre>vim start.sh</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Pbf5fUd-qh2q03u4wBLByw.png" /></figure><p>You’ll then enter in an empty document. Then, copy-paste the following lines:</p><pre>docker run --gpus all --rm -it -p 8888:8888 -p 8787:8787 -p 8786:8786 \<br>        -v &quot;$(pwd)/notebooks:/rapids/notebooks/host&quot; \<br>        rapidsai/rapidsai:cuda10.1-runtime-ubuntu18.04</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2mi1OdojX_8TXMQFCFDQjA.png" /></figure><p>Then, press :x to save and exit the document. What the above command will do is open a <em>new docker container</em> every time you run the <strong>start.sh</strong> file. The command also <strong>mounts </strong>the host folder, so you can create notebooks and save files in the Jupyter environment and still <strong>keep/reuse</strong> them even after terminating the session. <strong>Keep in mind that any libraries/packages you install in this container during the session are STILL going to be lost afterwards (I am still working on a solve to this).</strong></p><p>Now what remains is:</p><pre># make the file executable<br>chmod +x start.sh</pre><pre># run this line of code any time you want to open the environment<br>sudo ./start.sh</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P5cw_js9FEz9X4S2U6YPzw.png" /></figure><p>To open the Jupyter environment, open the browser and write in the <em>address bar</em> one of the following:</p><pre><a href="http://localhost:8888/lab">http://localhost:8888/lab</a>?    - to open Jupyter Lab</pre><pre><a href="http://localhost:8888/tree">http://localhost:8888/tree</a>    - to open the classic Jupyter Notebook</pre><p>You’ll see multiple folders there: if you’ll write a new notebook in any of them besides the host , they will be <strong>deleted</strong> after the end of the session. However, the notebooks you write in the host folder will <strong>remain</strong> and be available to check out in your “notebooks” folder (which is in my case located in the <strong>9.RAPIDS</strong> folder).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yMSl6bUViYeo_xDmaT6hEw.png" /><figcaption>the WEB envirnoment</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pKcREXmL6ixbUlnx-o-IVA.png" /><figcaption>the LOCAL folder with the saved files</figcaption></figure><p>After this, you can <em>safely enjoy</em> any RAPIDS library like cupy , cuml , cudf etc. In this opened environment in the terminal you can also install libraries as you would install them with the Anaconda prompt (example in <strong>orange </strong>below):</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xxLoxH5fnyE-3TDtuESe8w.png" /></figure><p>To check your memory usage and performance of the GPU devices, you have to run the following:</p><pre>sudo apt install nvidia-utils-455</pre><pre>nvidia-smi</pre><p>Afterwards, you should see something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vlkXatlsk802uomU-BzUFg.png" /></figure><p>The drawback to this method is that the libraries and changes to the environment are still going to be deleted after the end of each session, even if the files you created or updated will still be available on your machine.</p><p>I am currently working on a solve for this, as the references are quite poor, but I will update this article as soon as I find a solution.</p><h3>References</h3><ul><li><a href="https://docs.nvidia.com/cuda/wsl-user-guide/index.html#installing-wip">Install CUDA on WSL2</a></li><li><a href="https://rapids.ai/start.html">Getting started with RAPIDS Installation</a></li><li><a href="https://docs.microsoft.com/en-gb/windows/wsl/install-win10">Install WSL 2 documentation</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a31af966ef62" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>