These macros are used in the KLayout software, see its main page here. If you want to use the macro, you need to run the script first. After it finishes, you can go back to the KLayout's main window.