The following articles have been read in order to produce this code. https://blog.filippo.io/building-python-modules-with-go-1-5/#thecompletedemosource http://nigerlittlepoole.com/post/153224915028/using-go-to-boost-python-performance https://tip.golang.org/doc/go1.10#cgo https://docs.python.org/3/howto/cporting.html https://golang.org/cmd/cgo/ https://stackoverflow.com/questions/13417789/cgo-c-function-has-int-pointer-argument-how-to-pass-correct-type https://golang.org/pkg/io/ioutil/#TempDir https://docs.python.org/2/c-api/capsule.html https://github.com/spikeekips/embedding-python-in-golang/blob/master/pthreads2/main/main.go https://michael.stapelberg.de/Artikel/cgo_uint32