Python tutorials

A Hands-on Tutorial to Learn Attention Mechanism For Image Caption Generation in Python

Overview Understand the attention mechanism for image caption generation Implement attention mechanism to generate caption in python   Introduction The attention mechanism is a complex cognitive ability that human beings possess. When people receive information, they can consciously ignore some of the main information while ignoring other secondary information. This ability of self-selection is called attention. The attention mechanism allows the neural network to have the ability to focus on its subset of inputs to select specific features.  In recent […]

Read more

Guide to Parsing HTML with BeautifulSoup in Python

Introduction Web scraping is programmatically collecting information from various websites. While there are many libraries and frameworks in various languages that can extract web data, Python has long been a popular choice because of its plethora of options for web scraping. This article will give you a crash course on web scraping in Python with Beautiful Soup – a popular Python library for parsing HTML and XML. Ethical Web Scraping Web scraping is ubiquitous and gives us data as we […]

Read more

How to Plot Inline and With Qt – Matplotlib with IPython/Jupyter Notebooks

Introduction There are a number of different data visualization libraries for Python. Out of all of the libraries, however, Matplotlib is easily the most popular and widely used one. With Matplotlib you can create both simple and complex visualizations. Jupyter notebooks are one of the most popular methods of sharing data science and data analysis projects, code, and visualization. Although you may know how to visualize data with Matplotlib, you may not know how to use Matplotlib in a Jupyter […]

Read more

How to Concatenate Two Lists in Python

Introduction List concatenation the act of creating a single list from multiple smaller lists by daisy chaining them together. There are many ways of concatenating lists in Python. Specifically, in this article, we’ll be going over how to concatenate two lists in Python using the plus operator, unpack operator, multiply operator, manual for loop concatenation, the itertools.chain() function and the inbuilt list method extend(). In all the code snippets below, we’ll make use of the following lists: list_a = [1, […]

Read more

Fine-Grained Sentiment Analysis of Smartphone Review

How to conduct fine-grained sentiment analysis: Approaches and Tools Data collection and preparation. For data collection, we scraped the top 100 smartphone reviews from Amazon using python, selenium, and beautifulsoup library. If you don’t know how to use python and beautifulsoup and request a library for web-scraping here is a quick tutorial. Selenium Python bindings provide a simple API to write functional/acceptance tests using Selenium WebDriver. Let’s begin coding    

Read more

How to Deploy a Django Application to Heroku with Git CLI

Introduction Heroku is a cloud platform that provides hosting services. It supports several programming languages including PHP, Node.js, and Python. It is Platform-as-a-Service (PaaS) which allows you to manage website applications while it takes care of your servers, networks, storage and other cloud components. In this article, we’ll take a look at how to deploy a Django application to Heroku, using Git. You can follow the same steps, and deploy the application from GitHub, if it’s hosted there. Prerequisites Below […]

Read more

Ultimate Guide to Understand and Implement Natural Language Processing (with codes in Python)

Overview Complete guide on natural language processing (NLP) in Python Learn various techniques for implementing NLP including parsing & text processing Understand how to use NLP for text feature engineering   Introduction According to industry estimates, only 21% of the available data is present in structured form. Data is being generated as we speak, as we tweet, as we send messages on Whatsapp and in various other activities. Majority of this data exists in the textual form, which is highly unstructured […]

Read more

How to build your first Machine Learning model on iPhone (Intro to Apple’s CoreML)

Introduction The data scientist in me is living a dream – I can see top tech companies coming out with products close to the area I work on. If you saw the recent Apple iPhone X launch event, iPhone X comes with some really cool features like FaceID, Animoji, Augmented Reality out of box, which use the power of machine learning. The hacker in me wanted to get my hands dirty and figure out what it takes to build a system like […]

Read more

How to create a poet / writer using Deep Learning (Text Generation using Python)?

Introduction From short stories to writing 50,000 word novels, machines are churning out words like never before. There are tons of examples available on the web where developers have used machine learning to write pieces of text, and the results range from the absurd to delightfully funny. Thanks to major advancements in the field of Natural Language Processing (NLP), machines are able to understand the context and spin up tales all by themselves.               […]

Read more

Complete tutorial on Text Classification using Conditional Random Fields Model (in Python)

Introduction The amount of text data being generated in the world is staggering. Google processes more than 40,000 searches EVERY second!  According to a Forbes report, every single minute we send 16 million text messages and post 510,00 comments on Facebook. For a layman, it is difficult to even grasp the sheer magnitude of data out there? News sites and other online media alone generate tons of text content on an hourly basis. Analyzing patterns in that data can become […]

Read more
1 136 137 138 139 140 181