跟随,学习,进步

Stack Abuse

Stack Abuse features News, articles, and ideas for software engineers and web developers.

https://stackabuse.com
转到作者网站

Creating and Importing Modules in Python

Introduction In Python, a module is a self-contained file with Python statements and definitions. For example, file.py, can be considered a module named file. This differs from a package in that a package is a collection of modules in directories that give structure and hierarchy to the modules. Modules


Predicting Customer Ad Clicks via Machine Learning

Introduction Internet marketing has taken over traditional marketing strategies in the recent past. Companies prefer to advertise their products on websites and social media platforms. However, targeting the right audience is still a challenge in online marketing. Spending millions to display the advertisement to the audience that is not likely


The Python String strip() Function

In this article, we'll examine how to strip characters from both ends of a string in Python. The built-in String type is an essential Python structure, and comes with a built-in set of methods to simplify working with text data. There are many situations in which a programmer may want


The Python zip() Function

In this article, we'll examine how to use the built-in Python zip() function. The zip() function is a Python built-in function that allows us to combine corresponding elements from multiple sequences into a single list of tuples. The sequences are the arguments accepted by the zip() function. Any number of


Spring Cloud: Turbine

Overview In this article, we'll introduce you to Spring Cloud Netflix Turbine. It aggregates multiple Hystrix Metrics Streams into one, so that it could be displayed into a single dashboard view. To give a small introduction to Hystrix. In a microservice architecture, we have many small applications that talk to


Image Recognition in Python with TensorFlow and Keras

Introduction One of the most common utilizations of Tensorflow and Keras is the recognition/classification of images. If you want to learn how to use Keras to classify or recognize images, this article will teach you how. Definitions If you aren't clear on the basic concepts behind image recognition, it


Asynchronous Tasks in Django with Redis and Celery

Introduction In this tutorial I will be providing a general understanding of why celery message queue's are valuable along with how to utilize celery in conjunction with Redis in a Django application. To demonstrate implementation specifics I will build a minimalistic image processing application that generates thumbnails of images submitted


How to Send HTTP Requests in Java

Introduction Hypertext Transfer Protocol (HTTP) is an application-layer protocol, which without exaggeration, is pretty much is the backbone of Internet browsing as we know it. It's used for transferring hypermedia documents between the client and the server and is an essential part of every single web application, including any APIs


Non-Access Modifiers in Java

Introduction Modifiers are keywords that let us fine-tune access to our class and its members, their scope, and behavior in certain situations. For example, we can control which classes/objects can access certain members of our class, whether a class can be inherited or not, whether we can override a


Access Modifiers in Java

Introduction Modifiers are keywords that let us fine-tune access to our class and its members, their scope, and behavior in certain situations. For example, we can control which classes/objects can access certain members of our class, whether a class can be inherited or not, whether we can override a


Git: Merge Branch into Master

One of Git's most powerful features is the ability to easily create and merge branches. Git's distributed nature encourages users to create new branches often and to merge them regularly as a part of the development process. This fundamentally improves the development workflow for most projects by encouraging smaller, more


Python: Check if String Contains Substring

In this article, we'll examine four ways to use Python to check whether a string contains a substring. Each has their own use-cases and pros/cons, some of which we'll briefly cover here: 1) The in Operator The easiest way to check if a Python string contains a substring is


HashMap and TreeMap in Java: Differences and Similarities

The performance of a Java program and the proper use of resources are often depend on a collection a developer chose for storing data. Hence, it is very important to understand the difference between the implementations. That's why questions related to collections are in the top of interviews for Java


Python: Append Contents to a File

In this article, we'll examine how to append content to an existing file using Python. Let's say we have a file called helloworld.txt containing the text "Hello world!" and it is sitting in our current working directory on a Unix file system: $ cat ./helloworld.txt Hello world! Now assume


Overview of Async IO in Python 3.7

Python 3's asyncio module provides fundamental tools for implementing asynchronous I/O in Python. It was introduced in Python 3.4, and with each subsequent minor release, the module has evolved significantly. This tutorial contains a general overview of the asynchronous paradigm, and how it's implemented in Python 3.7.


Brief Introduction to OpenGL in Python with PyOpenGL

Introduction In this tutorial, we're going to learn how to use PyOpenGL library in Python. OpenGL is a graphics library which is supported by multiple platforms including Windows, Linux, and MacOS, and is available for use in multiple other languages as well; however, the scope of this post will be


Python for NLP: Working with the Gensim Library (Part 2)

This is my 11th article in the series of articles on Python for NLP and 2nd article on the Gensim library in this series. In a previous article, I provided a brief introduction to Python's Gensim library. I explained how we can create dictionaries that map words to their corresponding


Building GraphQL APIs with Vue.js and Apollo Client

Introduction GraphQL is a graph-oriented query language written by Facebook. In contrast to REST APIs, GraphQL introduces features that make API development more efficient and in tune with database models. GraphQL Features Unlike REST, there is only one endpoint where all requests are going to be sent to. So instead


Managing Environment Variables in Node.js with dotenv

Introduction Deploying an application requires developers to put thought and consideration into how it is configured. Many apps are deployed in a development environment before being deployed to the production environment. We need to ensure each environment is configured correctly, it could be disastrous if our production application was using


Working with PDFs in Python: Adding Images and Watermarks

Introduction Today, a world without the Portable Document Format (PDF) seems to be unthinkable. It has become one of the most commonly used data formats ever. Up to PDF version 1.4, displaying a PDF document in an according PDF viewer works fine. Unfortunately, the features from the newer PDF