Login  |  Join Us  |  Subscribe to Newsletter
Login to View News Feed and Manage Profile
☰
Login
Join Us
Login to View News Feed and Manage Profile
Agency
Agency
  • Home
  • Information
    • Discussion
    • Articles
    • Whitepapers
    • Use Cases
    • News
    • Contributors
    • Subscribe to Newsletter
  • Courses
    • Data Science & Analytics
    • Statistics and Related Courses
    • Online Data Science Courses
  • Prodigy
    • Prodigy Login
    • Prodigy Find Out More
    • Prodigy Free Services
    • Prodigy Feedback
    • Prodigy T&Cs
  • Awards
    • Contributors Competition
    • Data Science Writer Of The Year
    • Data Science Awards 2021
  • Membership
    • Individual
    • Organisational
    • University
    • Associate
    • Affiliate
    • Benefits
    • Membership Fees
    • Join Us
  • Consultancy
    • Professional Services
    • Project Methodology
    • Unlock Your Data
    • Advanced Analytics
  • Resources
    • Big Data Resources
    • Technology Resources
    • Speakers
    • Data Science Jobs Board
    • Member CVs
  • About
    • Contact
    • Data Science Foundation
    • Steering Group
    • Professional Standards
    • Government And Industry
    • Sponsors
    • Supporter
    • Application Form
    • Education
    • Legal Notice
    • Privacy
    • Sitemap
  • Home
  • Information
    • Discussion
    • Articles
    • Whitepapers
    • Use Cases
    • News
    • Contributors
  • Courses
    • Data Science & Analytics
    • Statistics and Related Courses
    • Online Data Science Courses
  • Prodigy
    • Prodigy Login
    • Prodigy Find Out More
    • Prodigy Free Services
    • Prodigy Feedback
    • Prodigy T&Cs
  • Awards
    • Contributors Competition
    • Data Science Writer
    • Data Science Awards 2021
  • Membership
    • Individual
    • Organisational
    • University
    • Associate
    • Affiliate
    • Benefits
    • Membership Fees
    • Join Us
  • Consultancy
    • Professional Services
    • Project Methodology
    • Unlock Your Data
    • Advanced Analytics
  • Resources
    • Big Data Resources
    • Technology Resources
    • Speakers
    • Data Science Jobs Board
    • Member CVs
  • About
    • Contact
    • Data Science Foundation
    • Steering Group
    • Professional Standards
    • Government And Industry
    • Sponsors
    • Supporter
    • Application Form
    • Education
    • Legal Notice
    • Privacy
    • Sitemap
  • Subscribe to Newsletter

Setting up a Python Jupyter Notebook Online & Working with Python on the Cloud

30 March 2020
Mayank Tripathi
Views (4842)
Comments (3)
Author Profile
Other Articles
Follow (13)

Share with your network:

Hello friends, today we will discuss on how we can work with Python without installing or doing any setup on our local machines or workstations. This will avoid the struggle to set-up the environment, if you have not done this before or if you are working on a computer that can’t handle the workload

In today’s world, the solution is the Cloud. There are 2 (as of my information, if you come across any new ones please let know, and I will be grateful to you) free Jupyter notebook environments where you can use free GPUs and TPUs which can solve these issues.

  1. Google Colaboratory
  2. Jupyter Notebook by CoCalc by SageMath, Inc

Let’s see how we can setup and start work within few minutes, hassle free.

Getting Started with Google Colaboratory

Please note that there are various ways to connect to Google Colaboratory.

Approach 1 →

To start working with Colab you first need to login to your google account, then go to this link https://colab.research.google.com which will open the page as shown below. And then you are all set to start.

Let’s understand what it offers. On opening the website, you will see a pop-up containing following tabs

 

EXAMPLES: Contains several Jupyter notebooks of various types.

RECENT: Jupyter notebooks you have recently worked with.

GOOGLE DRIVE: The Jupyter notebook in your google drive. I will be covering this in approach 2.

GITHUB: You can add Jupyter notebooks from your GitHub, but you first need to connect Colab with GitHub.

UPLOAD: Upload from your local directory.

You can create a new Jupyter notebook by clicking NEW NOTEBOOK at the bottom right corner. Or CANCEL if you do not wish to continue.

 

Approach 2 →

If you already have Google Drive, then you can directly go to Google Colab. Connect to your Google Drive account, and you will land on the page shown below and you are all set to start.

Let’s see what it offers.

 

From here we must use the navigation to open Google Colaboratory, as shown below.

 

On creating a new notebook, it will create a Jupyter notebook with Untitled0.ipynb (red encircled and marked as 1 see screenshot belwo) and save it to your google drive in a folder named Colab Notebooks. Now as it is essentially a Jupyter notebook, all commands of Jupyter notebooks will work here. Though, you can refer to the details in Getting started with Jupyter Notebooks.

 

Let’s talk about other options, from the above screenshot, check the red marked number 2, which is a working cell. This is to write Python code; be it for Machine Learning or any general Python Programming hands-on. An example is shown below.

This cell can also be converted from Python executable cell to markdown or plain text cell. This can be done either by using + Text as marked 3 in red

 

In Text we do have options to make the text bold, enclose the syntax as a code using < >, and so on.

 

To save the file, google provided options such as “Save a Copy in Drive”; “Save a copy as GitHub Gist”; “Save a copy in GitHub”. This can be done via navigating to File.

 

Another awesome option is moving the cell (be it executable code cell or text / markdown cell) up or down using the up arrow or down arrow.

 
  • Can Delete the Cell.
  • Link to Cell.
  • Add comments for a cell.
  • Copy Cell
  • Cut Cell
  • Edit Cell

Change Runtime Environment:

Click the “Runtime” dropdown menu. Select “Change runtime type”.

Another window will pop-up, from which you can select Python Version.

 

Select Python 2 or Python 3 from “Runtime type” dropdown menu.

 

Use GPU and TPU:

In a similar way to the above, or even as a continuations to the above, we can change the “Hardware accelerator” and set it to GPU or TPU based on your requirements.

Click the “Runtime” dropdown menu. Select “Change runtime type”. Now select anything (GPU, CPU, None) you want in the “Hardware accelerator” dropdown menu.

 

Download Jupyter Notebook:

Let’s say you want to download your working file. Click “File” dropdown menu at top left corner. Choose “download .ipynb” or “download .py”

 

Share Jupyter Notebook:

You can share your notebook by adding email addresses or by creating a shareable link. As red encircled.

 

Jupyter Notebook by CoCalc by SageMath, Inc

To start working with a Jupyter Notebook click on the link https://cocalc.com/doc/jupyter-notebook.html and it will ask you to Sign In.

Please do sign-in either create a new account or sign-in using your social network.

 

After sign-in, it will ask you to create a Projects file, this is to manage all your .py and data-set files.

Just give a name to your Project, for example I have used First Hands-On. You can have your own.

 

After that it will ask you to create or upload a file. For now, we will start with creating a new file, make sure to select “Select the type of file” as “Jupyter Notebook”.

 
 
 

And you are all set. We can start working with Machine Learning; Data Analysis or simple hands-on with Python.

 

Let’s understand what it offers.

Locate the file → Once created the file(s), we can list of files as below by clicking on Files.

 

Similar to Google Colab, Jupyter Notebook by Cocalc.com also provide Executable Cell / Plain Text (Markdown) / Raw. Refer red encircled. Also this is exactly same to what we do have on original Jupyter Notebook which we install on local machine.

 

Have options to Save, Copy, Cut, zoom in, Zoom Out, Print etc…

 

Once can also run or execute the cell in different ways as mentioned or red encircled.

  • Run cells → To run the selected cell..
  • Run cells and select below → To run the selected cell and either a new cell after running or if cell already available pointer will select to that cell.
  • Run cells and insert cell below → To run To run the selected cell and to create a new cell below after running.
  • Run all → Will run all the cells from top to bottom.
  • Run all above → Will run all the cell which are above of selected cell.
  • Run all below → Will run all the cell which are below of selected cell.
 

Similar to Google Colab, here too we have options to move the cell down or up using down arrow or up arrow respectively.

 

Cool… so we are all set with the Jupyter Notebook, and from next article will start directly jump into practical things and will have our hands dirty.

Please add comments if you face any issue in any of the step, will be happy to help.

Like (11)
Download

Email a PDF Whitepaper

If you found this Article interesting, why not review the other Articles in our archive.

Login to Comment and Like

Comments:

Ekta Tripathi

06 Apr 2020 06:08:02 PM

Wow this is really good as now we can do hands-on using the above online juypter notebook.


Balakrishnan Subramanian

10 Apr 2020 02:26:16 PM


JupyterLab is a web-based interactive development environment for Jupyter notebooks, code, and data. JupyterLab is flexible: configure and arrange the user interface to support a wide range of workflows in data science, scientific computing, and machine learning. JupyterLab is extensible and modular: write plugins that add new components and integrate with existing ones.

Abhishek Mishra

19 Apr 2020 06:26:25 PM

free Jupyter notebook environments where you can use free GPUs and TPUs which can solve these issues.

Google Colaboratory

Jupyter Notebook by CoCalc by SageMath, Quite a tip

Go to discussion page

Categories

  • Data Science
  • Data Security
  • Analytics
  • Machine Learning
  • Artificial Intelligence
  • Robotics
  • Visualisation
  • Internet of Things
  • People & Leadership
  • Other Topics
  • Top Active Contributors
  • Balakrishnan Subramanian
  • Abhishek Mishra
  • Mayank Tripathi
  • Santosh Kumar
  • Michael Baron
  • Recent Posts
  • Hadoop and MapReduce
    21 December 2020
  • The Concept of Data Quality and Its Importance
    17 December 2020
  • Leadership and what it means in challenging times
    16 December 2020
  • How Data Visualization Will Evolve In Future
    14 December 2020
  • Most Liked
  • Cyber Physical Systems
    Likes: 26
    Views: 4546
  • Green Computing: The Future of Computing
    Likes: 23
    Views: 883
  • Why AI is a great match for your data strategy
    Likes: 18
    Views: 1051
  • Advances in Data Science 2018: Final Speakers & Discussion Themes
    Likes: 16
    Views: 1249
  • Detecting Fraud Using Machine Learning
    Likes: 15
    Views: 651
To attach files from your computer

    Comment

    You cannot reply to your own comment or question. You can respond to another member's comment in this thread.

    Get in touch

     

    Subscribe to latest Data science Foundation news

    I have read and agree to the Data science Foundation Privacy Policy

    • Home
    • Information
    • Resources
    • Membership
    • Services
    • Legal
    • Privacy
    • Site Map
    • Contact

    © 2021 Data science Foundation. All rights reserved. Data S.F. Limited 09624670

    Site By-Peppersack

    We use cookies

    Cookie Information

    We are using cookies to provide statistics that help us to improve your experience of our site. You can choose to use the site without cookies. However, by continuing to use the site without changing your settings, you are agreeing to our use of cookies.

    Contact Form

    This member is participating in the Prodigy programme. This message will be directed to Prodigy Admin the Prodigy Programme manager. Find out more about Prodigy

    Complete your membership listing and tell others about your interests, experience and qualifications with a Personal Profile page.

    Add a Personal Profile

    Your Personal Profile page is missing information about your experience and qualifications that other members would find interesting. Click here to update.

    Login / Join Us

    Login to your membership account to view your personalised news feed, update your profile, manage your preferences. publish articles and to create a following.

    If you are not a member but work with or have an interest in Data Science, Machine Learning and Artificial Intelligence, join us today.

    Login | Join Us

    Support the work of the Data Science Foundation

    Help to fund our work and enable us to provide free communications and knowledge sharing services to members across the globe.

    Click here to set-up a donation of £30 per year

    Follow

    Login

    Login to follow this member

    Login