Computer simulations are an essential tool for the study of physical processes in a broad range of fields including chemistry, biology, physics, engineering, finance, and geology. Many of the most interesting events occur on timescales that are many orders of magnitude longer than is tractable to simulate directly. This challenge has motivated the development of numerous methods to enhance the sampling of rare dynamical events. ,In the first part of this work, we describe a multilevel preconditioning scheme that allows one to use a less expensive model to guide the exploration of the energy landscape of a more expensive but presumably more accurate model. Our preconditioning formalism maintains the stability of the solutions to the expensive model and is robust to the relative quality of the inexpensive model. We demonstrate how this multilevel scheme can be used to accelerate the convergence of path-refinement algorithms and geometry optimizations.,In the second part, we describe a general mathematical framework for trajectory stratification for efficiently simulating rare dynamical events. Trajectory stratification involves decomposing trajectories of a given stochastic process into restricted subsets in space and time, computing averages over the subsets independently, and recombining those averages in an appropriately weighted sum yielding averages of dynamical quantities over the original unbiased process. We demonstrate how this framework leads to a novel class of rare event methods that are capable of estimating a much broader class of dynamical expectations than was previously tractable. ,In the third part, we describe an open-source Python-based toolkit for rapid prototyping of enhanced sampling algorithms. The toolkit is a Python package that wraps commonly used molecular dynamics engines and provides a high-level and model agnostic programming interface for developing enhanced sampling algorithms. We illustrate how this programming framework facilitates expressive and portable implementations of enhanced sampling algorithms that are can be readily ported to HPC environments.