Programming

I am proficient in Python and Matlab, and have some knowledge of Rust, C++, Java, and Mathematica. My programming experience can be roughly divided into the following: scientific research, personal projects, open-source projects, and competitive programming.

Research

fastssb: Ptychography refers to any method for reconstructing high resolution images of something from a collection of interference patterns. Single side-band ptychography is one such method. I refactored an existing GPU-accelerated single side-band code and tried to make it useful for my labmates.

Multislice simulation codes

Multislice is a popular method for simulating (scanning) transmission electron microscopy experiments. Over the course of my PhD, I have worked on the source code of two multislice simulation codes: computem (also known as temsim) and Prismatic.

My work on computem: Changed it to a) read in an additional phase shift due to the sample’s magnetic fields and b) output 4D-STEM data sets. For more context, you can check out the paper (preprint, journal article). Furthermore, I added a fix to mitigate artifacts from limited real space sampling of projected atomic potentials (more details here). Source code on Github.

My work on Prismatic: A few bug fixes. Also made it able to read in an additional phase shift from a file. Source code on Github.

  • Prismatic-MISER - Starting with Prismatic, I created a variant of multislice simulation that involves the MISER algorithm, a Monte Carlo method suited for evaluating higher-dimensional integrals.

Personal Projects

  • Starlink constellation animation - I wrote Python scripts to produce an animation showing how the first shell of Starlink satellites was deployed and reached their target orbits.
  • edgecompare - Search program for edge lengths of hybrid Archimedean tilings of the hyperbolic plane.

Open Source

I try to contribute to open-source projects.

Hypermine - a voxel game in 3D hyperbolic geometry

MuseScore - music notation software

  • I have made some partial progress towards implementing numbered musical notation (Jianpu) in MuseScore. Code not yet published. Screenshot:
    partial Jianpu progress

Competitive Programming

  • Halite - From 2016 to 2019, Two Sigma sponsored three seasons of a programming competition called Halite, in which the participant writes a bot to play a real-time strategy game. After uploading your bot to the server, it will be automatically and continuously pitted against other bots, and you could then look at the replays of your bot’s games to see how to improve and climb the leaderboard. Very fun while it lasted. My Halite II bot; my halite III bot.
  • Advent of Code - In doing Advent of Code with some friends, I was gradually convinced to switch to Python and learn Rust. Here are my Advent of Code solutions.
  • Oort - A game in which you write programs to control spaceships and missiles in a space battle. I think this is very fun, especially if you have some basic physics knowledge. Since the game website is still accepting submissions, it is not yet time for me to share my code, but you can see one of my submissions in action here.
  • Project Euler - Math problems that usually require programming.

My current progress in Project Euler:

my current progress in Project Euler