Downsample

These are the commits that implement downsampling when importing instrument data.
Because downsample_ratio is used in 5 places, I have addressed this with a mixin. It will be a separate pull request.