Posts tagged "python":
1.) Access the remote server via ssh
2.) Start jupyter server on the remote machine
jupyter notebook --no-browser --port=8889
3.) Forward port 8889 from your remote machine to port 8888 of your local machine
ssh -N -f -L localhost:8888:localhost:8889 remote_user@remote_host
4.) Access the remote notebook from your local browser visiting localhost:8888
I find this very usefull, especially when working with plots and audio.
If you have comments, questions or opinions please drop me a line at 2018-08-04–remote-jupyter-notebook AT zngguvnf dot org. Please tell me whether it's ok to publish your comment here or not.
Make sure X forwarding is enabled on your remote machine
cat /etc/ssh/sshd_config | grep X11Forwarding
If the result it not
X11Forwarding yes adjust the file.
Access remote machine with X forwarding from your local machine.
ssh -X user@remote-host
On the remote machine: Activate X-compatible backend
import matplotlib matplotlib.use('tkagg')
On the remote machine: Plot as normal
import matplotlib.pyplot as plt plt.plot([1,2,3]) plt.show()
See plot on your local machine.
If you have comments, questions or opinions please drop me a line at 2018-07-21–matplotlib-on-remote-machine AT zngguvnf dot org. Please tell me whether it's ok to publish your comment here or not.
From 28.08 to 31.08 I was at the EuroScipy in Erlangen. There were about 200, mainly scientists from all over Europe, exchanged experiences they gained while working with Python. The people at the conference were very open and helpful.
The EuroScipy consisted of two days of tutorials and two days of conference.
The tutorials included two different tracks, one for beginners and one for advanced users.
From many people who were on the beginner track I heard that they just got started with Python. In my view, the conference is the perfect opportunity for this. With talk about Python, NumPy, Matplotlib, Pandas, SciPy and last but not least git you get a very good overview of the largest packages for scientific work with Python and additionally access to a very open and helpful community. Given the licensing costs of similar languages like Matlab, it should be worthwhile for companies to send their employees to 'training courses' like EuroScipy.
The conference talks were about 15 minutes long and full off new and exciting stuff, the lecturer build using Python.
Most of the time it felt like the presented project was a side project of their main research they want to share with the community.
I like this a lot. Lots of research is founded by public resources and I think it is the right way to make the results available to the public again.
A highlight of the EuroScipy 2017 for me was the keynote from Julia Rohrer with the title: 'How to Fix a Scientific Culture: Psychology as a Cautionary Tale and Paragon'.
In her talk Julia criticized that especially in psychological many scientific papers contain wrong evaluations. But due to missing data, analysis scripts and closed access the results are hard to reproduce.
With preregistration and Open Science Framework she named tools that fix this and improve the quality of science. In her lecture, she referred to the field of psychology but in the following discussion it quickly became clear that this is a multidisciplinary problem.
During the EuroScipy, however, I realized that everyone uses git and Jupyter notebooks. These are great tools for reproducible research. So it's time to use these tools not only for open source software and tutorials but also for publishing scientific work.
Besides tutorials and conference talks, the EuroScipy also consisted of a lot of very interesting conversations. It was amazing to talk to with people from completely different areas. Despite the different work fields everyone had similar problems which they resolved with the same Python toolboxes.
A highlight of the discussion for me was certainly a conversation with one of the core NumPy developer. Thank you, Julian!
All in all, I really enjoyed the open community at EuroScipy and I'm going to try to share more of what I do with other people in the future. Hopefully this blog is just the beginning. In the future, significantly more projects will be published on my GitHub account and maybe I'll be able to create a poster or a short talk for the next EuroScipy.
If you have comments, questions or opinions please drop me a line at 2017-09-06–euroscipy-2017 AT zngguvnf dot org. Please tell me whether it's ok to publish your comment here or not.