Giving something back

Let's face it, we've all been there. Here we post the things we think it can help the community to have a deep understanding and to solve common problems.

Tag – Python

How to deploy a django project with Apache + mod_wsgi

Posted by Andres Haskel

In this guide we will talk about how to deploy a django project using Apache and it’s module, mod_wsgi. This two have a main role in the deploying process.

We will handle the client requests using Apache, which will be the one of delegating the requests that need logic to the Django app through mod_wsgi.

Setting a virtual environment

First, we will install pip

$ sudo easy_install pip

Next we need to install the virtualenv command to create these environments.

$ sudo pip install virtualenv

When virtualenv gets installed we can create a Python virtual environment by typing:

$ virtualenv exampleve

Then, to ...

Read More

Python mongodb

Posted by Diego Insua

What is mongo?

Mongo is an open source non-relational database service, written in C++. It is the ideal tool for backend services that need to save information that needs little processing quickly. These characteristics make it ideal for mobile and social networks backend services.


Pymongo is an API used for managing mongo databases in python. It is really easy to learn, and straightforward to use. Let’s start with the basics; the first thing you need is a database and a collection to start.

For all of the examples the default “test” database will be used, and a collection called ...

Read More

Machine Learning in Python

Posted by Fabrizio Albertoni

Machine Learning is the science of building mathematical models automatically from data (a training dataset), without being explicitly programmed, in order to make predictions on new data. This has a large and growing number of applications, from spam filtering and fraud detection to facial recognition and autonomous vehicles. Machine learning algorithms have existed for a long time, but the computational power available today to perform complex mathematical calculations over huge datasets makes them have much more practical applications than ever. Recommendation systems like Netflix’s and Amazon’s, or Google’s self driving car are some of the most successful cases of machine ...

Read More

Map/Filter/Reduce in Python

Posted by Fabrizio Albertoni

What is Map/Filter/Reduce?

Map/Filter/Reduce is a high-level design pattern that simplifies the implementation of functions that operate over sequences (any datatype that has an iterator) making use of functional programming. This paradigm enables the programmer to treat sequences as a unit, making it possible to get rid of the entire control flow (no need of for or if statements).

How to use it

There are three basic functional operators: Map, Filter and Reduce. We will look over them one at a time and then see how they work together.


Map is a high-order function that ...

Read More

MapReduce and Hadoop

Posted by Fabrizio Albertoni


MapReduce is a programming model for processing and generating large datasets allowing massive scalability, inspired on the map and reduce primitives found in many functional programming languages. Basically, it refers to two separate tasks: the map job, which takes data and converts it into another set of data where each element is broken into key/value pairs, and the reduce job, which takes those pairs and combines them into a smaller set of data.

Programs that implement this paradigm can be automatically parallelized and executed on clusters of computers, since the input data can be partitioned. A system like ...

Read More

Django Channels

Posted by Ignacio Duran

What is “Django Channels” and why should it be used?

Django Channels is a way to include WebSockets and HTTP2 to your Django servers, and extend its basic functionalities. It allows frontend code to receive notifications either when data changes or an event triggers on the backend, without forcing the frontend to ask continually and periodically for updates to the backend. Django Channels also makes it possible for the server to run code after a response is sent to the user, allowing for quicker responses and easier data management.

The basic WebSocket functionality works in three steps. First the client ...

Read More