Skip to main content

Bayesian modeling of StarCraft II ladder performance

I've been in a bit of a pickle recently. I really need to figure out Bayesian inference as practice for my masters' thesis. I've been wondering, what kind of cool project - hopefully with my own data - could I make?, I thought as I fired up StarCraft II in the evening, as I usually do to unwind nowadays. What kind of fun use of PyMC3, the neat Python library for probabilistic programming, could I showcase?, I wondered as I watched my ladder ratings fall from the distraction. What kind of useful knowledge could I try to acquire using it?, I thought, watching my game performance fluctuate over the course of months.

And then it hit me.

Read more…

First JOSS review!

Several months ago, I stumbled upon the journal they call Joss. Well, actually, JOSS - the Journal of Open Source Software, "a developer friendly, open access journal for research software packages". It's a completely free, open-source and open-access alternative to established, for-(often-a-lot-of)-profit journals such as those by Reed-Elsevier or Springer.

And a few days ago, I've been called into service to review VlaPy, "1D-1V Vlasov-Poisson(-Fokker-Planck) Plasma Physics Simulation Tool". While I'm digging into that code, I thought I'd write something up about JOSS in general!

Read more…

Self-organized criticality - student project post-mortem

We just got finished with our student team project, which you can find here, and I thought I'd do a little post mortem on it.

It's a neat little project that implements various simulations of self organized criticality on 2D grids. What is self organized criticality, you might ask? Dunno, I can't tell you.

All right, I do know a little. Imagine the ising system I've written about before. In the version without an external magnetic field, it has a single important parameter that we can set - the temperature. If you sweep through the values of temperature, you can find a single point where the behavior of the system changes qualitatively - order wins over disorder at temperatures below roughly 2.72 in reasonable [set everything to 1] units. Near that value - at criticality - you get large scale behavior, huge fluctuations, exponential slowdowns, etc.

Self organized criticality, as I currently understand it, is basically that, except that as you run your simulation, you realize that it displays criticality for a wide range of parameters (here - temperature). To quote Wikipedia (emphasis mine):

the complexity observed emerged in a robust manner that did not depend on finely tuned details of the system: variable parameters in the model could be changed widely without affecting the emergence of critical behavior: hence, self-organized criticality.

Read more…

Update on the year 2019

2019 has been a weird year.

I don't feel like it's been all too good for my mental health, as I've definitely experienced burnout, mayhaps even depression. Suffice to say, the lows were low. I feel a bit like I procrastinated all there was to procrastinate.

It wasn't all bad, though - I'd say it was right up there in my top 25.

In trying to get some more work-life balance, I did get back to playing StarCraft - I'd cut it out of my life previously, along with all gaming - but I figured I do need some of that competitive drive in my life, and I still think there's a lot it can still teach me. You wouldn't drop chess from your life if you were passionate about it, right? So far, it's been treating me all right.

At the start of December, I started a research software job at the Institute for Plasma Physics and Laser Microfusion here in Warsaw, Poland! This is also where I'll be writing and developing my master's thesis, related to Bayesian inference for plasma diagnostics on Wendelstein 7-x, using Python and more specifically PyMC3. A step forwards for modern, open, reproducible and maintainable science software! At least, I hope so. :)

I was planning on putting some photos, stats etc here, but I haven't found the time to get to do those yet (remember all that procrastination? Yeah, it's coming back to bite me in the predictive posterior), and Matthew Rocklin says I should write shorter blog posts more frequently, anyway, and that sounds like good advice.

Thus, to get this out the door more quickly... onwards to 2020!

Simple Binder usage with Sphinx-Gallery through Jupytext

It's been a busy week for PlasmaPy. I recently found out about Binder support in sphinx-gallery. The latter is a package that we use to turn python scripts with comments into Sphinx pages and Jupyter Notebooks. I figured adding that could be a nice fit for our existing example gallery .

However, I quickly realized that the system in place is a bit unwieldy. Binder takes a link to an existing GitHub repository and executes .ipynb notebooks located there online. However, with sphinx-gallery, we don't have those notebooks in the repository - we have .py files with comments. The currently recommended way of setting this up with sphinx-gallery is keeping your built documentation in another repository and hosting it via something along the lines of GitHub Pages rather than ReadTheDocs, which we are currently using.

I added the results of this investigation to sphinx-gallery's docs, but I didn't want to switch away from RTD, so I figured I'd go ahead and find another way. I think I've got something that works well enough now!

Trigger warning: later on during this post, there may be monkeypatching of sphinx_gallery internals. Beware.

Read more…