Fixed problem when run with no directory argument, changed output folder to be named the same as parent folder, added more accepted file type names