Nathaniel R. Stickley

Software Engineer - Astrophysicist - Data Scientist

A Few Gotchas for Python Newbies

A Few Gotchas for Python Beginners Here are a few 'gotchas' for Python beginners to be aware of, in order to avoid simple errors that may not raise exceptions, and thus are difficult to detect. Be aware that Python uses row-major order, just like C. This is particularly important when dealing with NumPy arrays and […]

Cleaning up Ph.D. Python

As part of my job, I sometimes help graduate students and postdoctoral scholars to improve their code and their coding skills. The purpose of this post is to provide a high-level summary of what I try to teach them, and the advice that I give them, without delving into low-level, case-specific details.

Syncing VM Images Quickly

Sometimes, a trivial algorithm, when simply parallelized a bit, is much faster than a fancy algorithm that runs serially!

I recently implemented a simple algorithm for synchronizing fixed-size virtual machine images between my work laptop and desktop computer because rsync was taking several minutes to perform the task—even in cases when the disk image had barely changed. After reading a description of the rsync algorithm, it became clear why it was taking so long in this case.

Pandoc Markdown

I've been using the Pandoc document translator / compiler periodically for a few years now to create HTML documentation from Markdown. Recently, I started using Pandoc more frequently, so I took the time to develop a custom CSS style, nrstyle.css to make the documents look nicer. Here are some examples.

The fmt Library

The standard options for formatting strings in C++ are, frankly, annoying and cumbersome. Yesterday, I found a nice solution: fmt (formerly known as cppformat). Fmt is a ligthweight library that allows you to use a syntax that is very similar to the string formatting mini-language supported by Python's str.format() function and the Rust language's formatting syntax.

Somelight

Somelight is a Python module that I wrote to assist in garden planning—particularly plant placement—by computing the daily sunlight exposure at a specified set of points. The user simply specifies the shapes of nearby objects that can potentially shade their garden and then uses Somelight to compute the sun exposure on a specified date (or range dates).

Euclid Software Development Notes

This page contains my personal notes on Euclid software development. I am putting concise summaries of the Wiki content and links to longer documents here, since the Euclid Redmine website is currently a bit of a rat's nest.

Frequently-Referenced Python

I am reserving this spot to put links to Python pages that I often reference. The things I put here are bits of syntax (for Python itself and library APIs) that are easily forgotten. For example, the string formatting mini-language is something that I have trouble remembering, so I refer to https://pyformat.info/

Simple Deep Neural Network Code

During my final days at UCR, I developed an artificial neural net code in C++ in order to get a more complete understanding of deep learning. I used that code to make the following animation, which shows a very small artificial neural network learning a function.

Debian / Ubuntu System Administration Roadmap

This is intended to be a brief summary of the basic knowledge and skills needed in order to maintain the NebulOS cluster at UC Riverside, starting at a low level. More generally, this is a concise roadmap (or outline) for Ubuntu Linux system administration. In this roadmap, I will point you to resources that can be used to learn more. The purpose of this is not to explain everything in detail; it will merely get you started. Note that some of the things mentioned here are specific to Ubuntu or Debian-based operating systems, so this isn't exactly a general Linux system administration roadmap.

Wormhole

Wormhole uses the Linux kernel's inotify functionality to react to filesystem events. More specifically, it watches a directory and performs user-specified actions on any files that are moved into or written to the directory. Once the files are processed, the results are stored in another directory. Wormhole was initially developed to provide a means of automatically compressing files before they are transferred via NFS, and then decompressing the files after they have been transferred.

New Blog

When I was a graduate student, I started a research blog at my personal website, idius.net. About one year after completing my Ph.D., I created nrstickley.com as a professional profile / résumé. I will now continue the blog here. I may eventually import some of the old posts into this blog, but until then, readers can refer to http://www.idius.net/my-research/research-log/ for older posts.

Nathaniel R. Stickley
nrs@nrstickley.com
626-269-9830