---
layout: post
title: "Python Threading with External Processes"
tags:
- Python
- Multithreading
---

## Notes for now

# Introduction
Very often when you write python scripts you might realize that the steps in one of your loops are actually not dependent on each other, so you could [parallelize](https://en.wikipedia.org/wiki/Parallel_computing) them. In it's simplest form, to parallelize computations python offers ready made *threads* and *locks*. There are two distinct ways to parallelize computation in python, either through Multiprocessing (and the according multiprocessing package) or Threading (and the according threading package), the pros and cons are excellently summarized by Jeremy on [stackoverflow](http://stackoverflow.com/a/3046201/5882522). This post only offers a toy example for the use of the threading example.

# Toy Example
The example code

# Threading package
The threading package offers threading. Note GIL that can be surcumvented by external processes and similar.
Shortly try to understand what threads actually are

# Code

Add draft for threading with external processes
Add draft for threading with external processes
