Added logging and ArgumentParser