"Compiling" Python to run on another machine
<p>I have created a simple-medium complexity script written in Python using Pycharm on my laptop and I wish to run this on my Raspberry Pi using Crontab. All of my past programming experience has been with C++ and C# in Windows and so I would normally just do a build of the project and it all gets compiled and linked into a single executable file.</p>

<p>For Python how do you "compile" the script so that it can be run on another PC? I use some external libraries (requests and ImgurClient) which I had to install using the Pycharm app. I guess I'm correct in thinking that these need to be taken across to the RaspPi too? My script is in two files and so do I need to copy both of these files across? Is there a way to build them into a single file to use easily?</p>

<p>This is my first script which I've written just from my knowledge of other languages and a bit of Googling. Just don't know how to proceed now that I have the actual script.</p>

<p>Python does not need to compile as it is an interpretive language. You will be fine running it on another machine as long as you aren't making system calls. System calls will only become a problem if you are trying to do things like use windows commands on a linux machine.</p>

<p>Just copy those two files over to the pi and run like normal. Or from the terminal</p>

<pre><code>python program.py
</code></pre>

python cron pycharm