VSCode on Browser (iPad/Android) with ColabCode | Google Colab Python

1littlecoder · Intermediate ·📰 AI News & Updates ·5y ago

Key Takeaways

Sets up and runs VSCode on browser with ColabCode and Google Colab

Full Transcript

hey friends welcome to one little coder do you know that you can actually access vf code on your browser yes that is possible with github code spaces github code spaces is a hosted environment for a vs code so you can actually open vs code and then do everything that you do with your computer's vs code but the problem with codespace is that it is still in early beta and a lot of people have not got access even after requesting access but what if you want something that is like codespace where you can access vs code in the browser uh without you know you have to set up much and that is where collab code comes into picture thanks to abhishek toggle for putting together this package so collab code is a python package that helps us spin up a vs code instance quickly on google collab so vs code has an open source version called code server so that code server can be installed on any next mission and that's what is happening under the code between behind collab code so let's quickly go ahead and see how we can access collab code and vs code on our browser so i've got a vs a google collab environment which i'm not connected by the way which is a mistake i'm sorry uh that would probably take some time so while it is getting connected so the simple way for us to install collab code is pip uh install collab code so after we install collab code so you can actually see the see the documentation there are two ways you can access collab code one is uh from terminal as a command um like typically how you do with the clies and the other is within a python code so what we're going to do in this tutorial is we're going to look at the way how to do with python code so the other thing that i wanted to highlight here is collab code by default itself will give you an ngrok instance and then now it will give you a link but if you want to use your own in croc it's always better to set up your own ingrock and take authentication from there and uh the advantage with that is you get a slightly longer ingrock session you have control over the url that you get so first we will see normal collab code instance then we will see how to do use the other features of collab code so right now we have installed collab code successfully next is from collab code import collab code just slightly you have to pay attention to the cases so it's propagation that is um um small case so after you do that you can just simply say collab code and then you can just fire it up you can like simply do it without you know adding any parameters so let's do it before that you can actually see code is equal to true by by default lab is equal to false we have already got another video which shows how you can use jupyter lab on your browser you using collab code with this video specifically for vs code so we are right we are going to leave it as a discord is equal to true and let's run it and once we run it we would uh we would get a collab sorry a vs code instance with an ngrok url and once we click the incro url the vs code instance should ideally open so you can see that it is working i've not edited this video so you can actually understand how much time it takes so click this link it will take you to a url where you would see the hosted uh vs code environment very similar to codespace if if ever you get code space and when i say very similar to codespace the reason i say that is you can copy this link and then paste it on your tablet or ipad wherever it is so so it is truly you know browser based like no need for any platform or anything so basically what has happened is this code server has got installed on the collab machine on the machine that google has given you so as long as that session is active and as long as your ingroud title is active this link would work so let's quickly see before even we see that i would like to also show another quick instance so now that you saw that the vs code is ready sometimes you know you want to protect your instance with the password and that is also available here password is equal to let's say one little quarter and while we do this i would also show you that uh we can use our own in rock authentication so when you install ngrok you can go to encroach dashboard and then you would see your authentication code here it's always not advisable to share your code with anyone so i'm just making it for this video i would reset it up this video so take your authentication authentication code token then save it probably you can delete it then then you can say uh definitely this is not the way you use an authentication token probably you can use environment variable um or a token file but i'm just showing it for simplicity okay and now if we fire it up so it would have uh it would use our in grog instance and also it would ask a password before it uh it lets somebody or anybody use uh the vs code instance so then grog url so we click the url it is asking for password and you know what is the password that we give so once i enter the password it's going to ideally take me to that place and then we'll uh we'll write a sample python code and then we'll see how how things work and what what kind of things are there so this this ngrok url you can now take this and then open it in any browser or anywhere else like it is not this um browser specific like uh if if i if i want okay let me first even in fact before that i'll let me create a create a file new file and uh let me call uh let me you know just write a sample python file and put pandas as pd i think you can sorry you can see let me zoom it in um if you want to you know change the theme color theme i want let let's say dark so change it to dark you can like everything that you do um select uh select python yeah um c bond as sns and then uh let's quickly write something df is equal to sns.load dataset of tips and um sns plot is equal to s dot scatter plot x is equal to total bill y is equal to um y is equal to okay i don't want to play with the indentation y is equal to tip and data is equal to df and once we have that um sns plot dot figure dot safe figure i think let me just quickly see seabond safe figure [Applause] we should get yes a fig output fig vscode.png so right now we have successfully created a python file so now we are going to say saying sample uh cbond we are saving it in the root file once you save that you can now invoke your terminal new terminal once we have the terminal in place let's uh let's look for the current files so c1 is there so python sample yeah the other thing that i forgot to mention is uh when you open vs code by default you get the python installed you don't have to install python extension for vs code it also comes with jupyter so you can do that um yeah right now we don't have files open i should have probably opened the files root file let me open the root folder now it's going to slightly you know close and open again because i'm i'm making my root folder the current folder someone root c bond is there output vs code is there and you can see the file so let's say you want to make some change um say i want to set a title set title and what's the title title vs code browser bad title but um yes uh open your terminal you can use shortcuts as well if you want open your terminal say python sample executed to get a new vs code after it gets executed no new image and then you got vs code browser and then the image so basically everything that you can do with the vs code you can actually do you can set git if you want um you can install any extension that you want you can do code debugging if you want like whatever code you want to debug you can debug so basically you get a full-fledged proper vs code editor on the browser and also the fact is that you it it is predicted with a password so you can share this link so what i wanted to show next is to quickly show you how you can take this link and then open it somewhere else so let me let me get a chrome instance which is uh you know which is not this browser so like that means my google is not open so which means my collab instance is not open so but still i'm going to show you that just because you have this ngrok url and you know the password you can actually log into that and then access the same code space so this could be really helpful if you are doing a code pairing or your your working on a pair programming or you're working on a project university project or a team project where you want to share the code with you know others so that's one advantage i think the biggest advantage is leveraging google collapse machine so if you're working on a machine learning project sometimes you may not want to actually code on a jupiter environment i mean uh jupiter is good collab environment but not every time you you actually like a jupiter you know notebook setup so that is the instance where you would probably want a proper id code editor and uh vs code is you know one of the most popular code editors that is currently available and then if you can get vs code on a powerful collab machine i think that is um that is a real win-win for anyone who does it so as you can see we can successfully see this this on a different machine so if you want you can like change color theme like um let's say on change something you you can like totally play with whatever you want like solar is light so you can play with whatever you want everything is same see you change here and then you would see things getting changed here uh this is this is sample editing once you get it you go here so you see that so it is really good for even pair programming and then you know you have a centralized environment in your organization like probably if you are a big corporate you may not need this but if your startup this is extremely handy and like i said if you get uh your own ingrock url and then your own authentication you get a longer session and then you can start leveraging that so i i hope this is really helpful and like everyone who misses codespace should definitely rigid because even if you do not have a computer all you need is you know a tablet and a keyboard bluetooth keyboard connected you have access to gpu tpu and powerful linux mission then you can actually do machine learning or any any sort of software development on a proper ide that is quite popular in the entire world so this is quite helpful and once again thanks to abhishek talker for putting putting out this package if you really like this package go ahead and then give star uh to the package and then give a shout out to the developer on twitter or linkedin wherever you know you are um you can read more about it what kind of other use cases are there like i said this this package can also be used to spin up a jupiter lab instance and i've made a separate video for that i'll link that video you can you can see it uh at the top right and thank you so much for listening to me if you have any questions please let me know in the comment section otherwise happy programming and stay safe

Original Description

If you have applied for Github CodeSpace Early Access and you've not got it? No worries, VSCode (Visual Studio Code) can be accessed on any browser - VSCode on iPad, VSCode on Android Tablet - powered by Google Colab. Thanks to Abhishek Thakur's ColabCode, In a few lines of Python code you can spin up a VSCode App on Google Colab instance. colabcode - https://github.com/abhishekkrthakur/colabcode ngrok - https://ngrok.com If you want to access JupyterLab on Browser (powered by Google Colab) - here's how - https://www.youtube.com/watch?v=Q35WIqZoUF4
Watch on YouTube ↗ (saves to browser)
Sign in to unlock AI tutor explanation · ⚡30

Playlist

Uploads from 1littlecoder · 1littlecoder · 0 of 60

← Previous Next →
1 How to create your Free Data Science Blog on Github with Fastpages from Fastai
How to create your Free Data Science Blog on Github with Fastpages from Fastai
1littlecoder
2 Making Interactive Matplotlib Plots for Data Science Visualizations on Jupyter (Python)
Making Interactive Matplotlib Plots for Data Science Visualizations on Jupyter (Python)
1littlecoder
3 Create your first Data Science Web App using R Shiny
Create your first Data Science Web App using R Shiny
1littlecoder
4 How to create a Reproducible Example in R using reprex
How to create a Reproducible Example in R using reprex
1littlecoder
5 No Code Visualization using esquisse with Tableau-like Drag and Drop GUI in R
No Code Visualization using esquisse with Tableau-like Drag and Drop GUI in R
1littlecoder
6 Scrape HTML Table using rvest and Process them for insights using tidyverse in R
Scrape HTML Table using rvest and Process them for insights using tidyverse in R
1littlecoder
7 Google Teachable Machine Learning Build No Code AI solution
Google Teachable Machine Learning Build No Code AI solution
1littlecoder
8 Create meaningful fake tidy datasets in R using fakir [#rstats Package]
Create meaningful fake tidy datasets in R using fakir [#rstats Package]
1littlecoder
9 How to enable using R Programming with Visual Studio VS Code
How to enable using R Programming with Visual Studio VS Code
1littlecoder
10 Python, Community, Books - with Abhiram R - Bangpypers Co-organizers | 1littlecoder podcast
Python, Community, Books - with Abhiram R - Bangpypers Co-organizers | 1littlecoder podcast
1littlecoder
11 Growing a Tech Community across India - Anubha Maneshwar, Founder Girlscript | 1littlecoder Podcast
Growing a Tech Community across India - Anubha Maneshwar, Founder Girlscript | 1littlecoder Podcast
1littlecoder
12 Intro to Google Colab - How to use Colab
Intro to Google Colab - How to use Colab
1littlecoder
13 Intro to Plotly Express - Complex Interactive Charts with One-Line of Python Code
Intro to Plotly Express - Complex Interactive Charts with One-Line of Python Code
1littlecoder
14 Indic NLP Python Toolkit Open Source Development - iNLTK Creator Gaurav Arora | 1littlecoder Podcast
Indic NLP Python Toolkit Open Source Development - iNLTK Creator Gaurav Arora | 1littlecoder Podcast
1littlecoder
15 Do you want a career in Data Science - Tamil Webinar
Do you want a career in Data Science - Tamil Webinar
1littlecoder
16 Android Smartphone Analysis in R [Live Coding Screencast]
Android Smartphone Analysis in R [Live Coding Screencast]
1littlecoder
17 Programmatically create Images, Memes, Watermarks using Python with imgmaker
Programmatically create Images, Memes, Watermarks using Python with imgmaker
1littlecoder
18 Kaggle Walkthrough to get you started with Data Science - Webinar
Kaggle Walkthrough to get you started with Data Science - Webinar
1littlecoder
19 Community, Corporate Job, Coding - Gnana Lakshmi T C aka Gyan, WomenWhoCode Leadership Fellow
Community, Corporate Job, Coding - Gnana Lakshmi T C aka Gyan, WomenWhoCode Leadership Fellow
1littlecoder
20 Easy ggplot2 Theme Customization with {ggeasy} | Data Visualization in R
Easy ggplot2 Theme Customization with {ggeasy} | Data Visualization in R
1littlecoder
21 Excel to R - Pivot + Bar Chart in Excel  & R using tidyverse [Live Coding]
Excel to R - Pivot + Bar Chart in Excel & R using tidyverse [Live Coding]
1littlecoder
22 Excel to R #2 - VLOOKUP in Excel to LEFT_JOIN, MERGE in R
Excel to R #2 - VLOOKUP in Excel to LEFT_JOIN, MERGE in R
1littlecoder
23 5 websites to get Free Real-World Datasets for Data Science/ML Projects
5 websites to get Free Real-World Datasets for Data Science/ML Projects
1littlecoder
24 Excel to R #3 - APPROXIMATE VLOOKUP in Excel to FUZZY LEFT_JOIN in R
Excel to R #3 - APPROXIMATE VLOOKUP in Excel to FUZZY LEFT_JOIN in R
1littlecoder
25 Correlation-alternative PPS (Predictive Power Score) Python Package Demo
Correlation-alternative PPS (Predictive Power Score) Python Package Demo
1littlecoder
26 Automated Website Screenshots in R using {webshot}
Automated Website Screenshots in R using {webshot}
1littlecoder
27 Installing Custom RStudio Theme (Synthwave85)
Installing Custom RStudio Theme (Synthwave85)
1littlecoder
28 Analyse Google Trends Search Data in R using {gtrendsR}
Analyse Google Trends Search Data in R using {gtrendsR}
1littlecoder
29 3 Tips to ask question on Stack Overflow the right way to get answers
3 Tips to ask question on Stack Overflow the right way to get answers
1littlecoder
30 Learn Data Science with R - Mini Projects - Web Scraping Zomato
Learn Data Science with R - Mini Projects - Web Scraping Zomato
1littlecoder
31 Easily make Dumbbell Chart using {ggcharts} | Data Visualization in R
Easily make Dumbbell Chart using {ggcharts} | Data Visualization in R
1littlecoder
32 GET Hackernews Front Page Results using REST API in R
GET Hackernews Front Page Results using REST API in R
1littlecoder
33 Quickly deploy ML WebApps from Google Colab using ngrok
Quickly deploy ML WebApps from Google Colab using ngrok
1littlecoder
34 Use Jupyter Notebooks within VSCode (Visual Studio Code) in 2020
Use Jupyter Notebooks within VSCode (Visual Studio Code) in 2020
1littlecoder
35 Plotly Interactive Plots as Pandas Plotting Backend df.plot()
Plotly Interactive Plots as Pandas Plotting Backend df.plot()
1littlecoder
36 Stack Overflow Developer Survey 2020 Highlights for New Programmers
Stack Overflow Developer Survey 2020 Highlights for New Programmers
1littlecoder
37 Matplotlib Animation Charts in Python using Celluloid
Matplotlib Animation Charts in Python using Celluloid
1littlecoder
38 Coding, Postwoman, Passion Project Book - Liyas Thomas Open Source Developer - 1littlecoder podcast
Coding, Postwoman, Passion Project Book - Liyas Thomas Open Source Developer - 1littlecoder podcast
1littlecoder
39 Aspiring Data Scientist, Tips on How to learn Business Domain Knowledge
Aspiring Data Scientist, Tips on How to learn Business Domain Knowledge
1littlecoder
40 Bokeh Interactive Charts as Pandas Plotting Backend df.plot_bokeh()
Bokeh Interactive Charts as Pandas Plotting Backend df.plot_bokeh()
1littlecoder
41 Easy Fast Python Pandas Summary with Sidetable | Pandas Tips & Tricks
Easy Fast Python Pandas Summary with Sidetable | Pandas Tips & Tricks
1littlecoder
42 Inception, Content Ideas, Consistency - Srivatsan Srinivasan AIEngineering YouTube Content Creator
Inception, Content Ideas, Consistency - Srivatsan Srinivasan AIEngineering YouTube Content Creator
1littlecoder
43 ggplot2 Text Customization with ggtext | Data Visualization in R
ggplot2 Text Customization with ggtext | Data Visualization in R
1littlecoder
44 Penguins Dataset Overview - iris alternative | EDA Data Visualization in R
Penguins Dataset Overview - iris alternative | EDA Data Visualization in R
1littlecoder
45 YouTube Growth Tips, Content Creation - Bhavesh Bhatt, YouTuber (Data Science & Machine Learning) #7
YouTube Growth Tips, Content Creation - Bhavesh Bhatt, YouTuber (Data Science & Machine Learning) #7
1littlecoder
46 Matplotlib Animated Bar Chart Race in Python | Data Visualization
Matplotlib Animated Bar Chart Race in Python | Data Visualization
1littlecoder
47 Simple Python GUI Development using {guietta}
Simple Python GUI Development using {guietta}
1littlecoder
48 #8 Niche, Growth, Monetization - David Langer - YouTuber Dave on Data
#8 Niche, Growth, Monetization - David Langer - YouTuber Dave on Data
1littlecoder
49 Simple Fast 3-step Python OCR using Deep Learning 40+ Languages
Simple Fast 3-step Python OCR using Deep Learning 40+ Languages
1littlecoder
50 Github New Feature Profile Summary/Mini-Resume - Profile Views
Github New Feature Profile Summary/Mini-Resume - Profile Views
1littlecoder
51 Otto ML Assistant, GPT-3 on Philosophers, Nvidia-ARM - 3 ML Tech News
Otto ML Assistant, GPT-3 on Philosophers, Nvidia-ARM - 3 ML Tech News
1littlecoder
52 What is OpenAI GPT-3 - Hype, Examples, Worries
What is OpenAI GPT-3 - Hype, Examples, Worries
1littlecoder
53 Julia 1.5, Datamuse API, Live HDR+ Pixel 4a - Machine Learning Tech News
Julia 1.5, Datamuse API, Live HDR+ Pixel 4a - Machine Learning Tech News
1littlecoder
54 Self-driving Car Engineer sentenced, arXiv Dataset, AI/ML Startup Idea - Machine Learning Tech News
Self-driving Car Engineer sentenced, arXiv Dataset, AI/ML Startup Idea - Machine Learning Tech News
1littlecoder
55 GPT-3 Explorer, Ciphey (Automated Decryption), Py-Sudoku - ML Tech News
GPT-3 Explorer, Ciphey (Automated Decryption), Py-Sudoku - ML Tech News
1littlecoder
56 How to use Advanced Google Search to extract Email Ids from Linkedin
How to use Advanced Google Search to extract Email Ids from Linkedin
1littlecoder
57 Cartoonizer Toon-IT (AI Web App), GPT-3 Advice, Android Earthquake Detection - ML Tech News
Cartoonizer Toon-IT (AI Web App), GPT-3 Advice, Android Earthquake Detection - ML Tech News
1littlecoder
58 Flow - R Package to visualize code logic, functions as a Flow Diagram
Flow - R Package to visualize code logic, functions as a Flow Diagram
1littlecoder
59 Build GPT-3-like Language Model on Google Colab with minGPT [PyTorch]
Build GPT-3-like Language Model on Google Colab with minGPT [PyTorch]
1littlecoder
60 Create a Pencil Sketch Portrait with Python OpenCV
Create a Pencil Sketch Portrait with Python OpenCV
1littlecoder

Related Reads

📰
Is the AI bubble about to burst? A data scientist’s honest take
A data scientist shares their honest take on whether the AI bubble is about to burst, providing an informed perspective on the technology's potential and limitations
Medium · AI
📰
Is the AI bubble about to burst? A data scientist’s honest take
A data scientist shares their honest take on whether the AI bubble is about to burst, providing a grounded perspective on the technology
Medium · Machine Learning
📰
Is the AI bubble about to burst? A data scientist’s honest take
A data scientist shares their honest take on whether the AI bubble is about to burst, providing a grounded perspective on the technology
Medium · Data Science
📰
Is the AI bubble about to burst? A data scientist’s honest take
A data scientist shares their honest take on whether the AI bubble is about to burst, providing a grounded perspective on the technology
Medium · Startup
Up next
Tackling Malaria in Africa with Technology at the Huawei ICT Competition
Huawei
Watch →