I created a pretty large Python project with multiple GUIs. I was thinking of creating an executable from it using py2exe, which automatically includes all packages you're using and it formats the files so that imports and everything will run fine. 
However, there are lines in my code where I load the UI from a path:
self.ui = uic.loadUi('C:/peter/myfolder/stuffs/sub_ui/ManualBalanceUI.ui', self.window)
Where ManualBalanceUI.ui is the file that Qt Designer creates. I want to write it in a way that it will always open for any user. How should I change that line of code so that it will always be able to load ManualBalanceUI.ui, which is located in the sub_ui folder in the main package? Is there any way I can change the base path to something like os.getcwd(), and then do something like
self.ui = uic.loadUi(os.getcwd() + 'sub_ui/ManualBalanceUI.ui', self.window)
What would be the best way to approach this problem? Thanks
 
     
    