Fix some formatting and imports.
Rename test file.
Update .gitignore.
Refactor into centrality package.
Update license.

We will need to update all the license headers later.