Aug-08-2017, 11:29 AM
Hello,
First post. New to Python. From a Java background.
I am trying to create a simple GUI for using existing Python scripts without having to use terminal and have run into a brick wall when trying to pass arguments to a method in the script. The method from the script I am trying to pass args to is called alignMain(args) and has such args as args.outputDir args.inputDir.
I am trying to call it like this from my script:
align_dlib.alignMain(outputDir=alignDir.get(), inputDir=rawDir.Get(), landmarks=landmark)
The error I get is: TypeError: alignMain() got an unexpected keyword argument 'outputDir'
Then as a test, I tried without the keyword and I get this error: AttributeError: 'str' object has no attribute 'outputDir'
What am I doing wrong here?
Thank you. (Happy to provide more info if needed.)
First post. New to Python. From a Java background.
I am trying to create a simple GUI for using existing Python scripts without having to use terminal and have run into a brick wall when trying to pass arguments to a method in the script. The method from the script I am trying to pass args to is called alignMain(args) and has such args as args.outputDir args.inputDir.
I am trying to call it like this from my script:
align_dlib.alignMain(outputDir=alignDir.get(), inputDir=rawDir.Get(), landmarks=landmark)
The error I get is: TypeError: alignMain() got an unexpected keyword argument 'outputDir'
Then as a test, I tried without the keyword and I get this error: AttributeError: 'str' object has no attribute 'outputDir'
What am I doing wrong here?
Thank you. (Happy to provide more info if needed.)