I cleaned up the Python script a bit to be more generic, made some dependencies optional, and put up a rough documentation: