First cleanup and bug fixes.

Add copyrights to .py files. Comment a bunch of print statements.
Add json encoder for numpy.ndarray, which reduces significant digits.
Add logging. Units and long_name are passed to plots.