Buffering writes

Many scientific computing applications consist of processing data and then writing out to disk. Often the application will be I/O bound, which means that the computation time is shorter that the time it takes to read or write data to disk. Even though modern OSes do their best to write efficiently to the hardware, there… Read More Buffering writes

Mixins or composition?

Mixins are great for “horizontal scaling” by adding functionality to a class over time. Reading mixed in code has an element of “gotcha” because the methods are scattered over multiple classes. Composition is great for handling complex functionality by insulating individual parts into their own classes and just exposing the bare interface to each other… Read More Mixins or composition?

Some macOS + Pyside2 tips

A live document, from the school of hard knocks … Get macOS to use a fixed width font: setFont(QFontDatabase.systemFont(QFontDatabase.FixedFont)) Get QTabWidget to have tabs on the left side and looking “professional” self.setDocumentMode(True) An epic can be written about the confusing behavior of menus on macOS, but the main reading material is https://doc.qt.io/qt-5/qmenubar.html#qmenubar-as-a-global-menu-bar menu.setNativeMenuBar(False) # We… Read More Some macOS + Pyside2 tips


Mixins are classes which are not meant to be used by themselves but instead are meant to be combined with other mixins on top of a base class to extend the functionality of that class. They are a great way to modularize code and make class features compose-able. Mixins are best explained using a simple… Read More Mixins!