- Posts: 1
Run SAM simulation from command line
- johncadigan@psg-inc.net
- Topic Author
Less
More
19 Mar 2019 14:42 #6711
by johncadigan@psg-inc.net
Run SAM simulation from command line was created by johncadigan@psg-inc.net
Hello,
I have a use case to run batch SAM simulations. To do this I have an external controller to change parameters that will either interface with the SAM scripts, or command line args.
I want to be able to run my simulation after I have generated the code from the SAM UI and interfaced the code with my parametric controller software. I have a few questions:
1. Do I need both SAM and SAM SDK to execute simulations from command line?
2. Also, how do I actually execute from terminal? I have tried executing python scripts that were generated from the SAM UI, but do not seem to gather output results.
Thanks in advance!
I have a use case to run batch SAM simulations. To do this I have an external controller to change parameters that will either interface with the SAM scripts, or command line args.
I want to be able to run my simulation after I have generated the code from the SAM UI and interfaced the code with my parametric controller software. I have a few questions:
1. Do I need both SAM and SAM SDK to execute simulations from command line?
2. Also, how do I actually execute from terminal? I have tried executing python scripts that were generated from the SAM UI, but do not seem to gather output results.
Thanks in advance!
Please Log in or Create an account to join the conversation.
- pgilman
Less
More
- Posts: 5423
19 Mar 2019 17:57 #6712
by pgilman
Replied by pgilman on topic Run SAM simulation from command line
Hello,
You can access the SAM application programming interface (API) from scripts or programs you write in various languages. The SDK provides everything you need to do that, so you don't need SAM to run the simulations once you have your environment set up.
It's a good idea to generate code from a case in SAM as you did because that automatically creates a ready-to-run script or program that you can start from.
Are you running the Python script from the folder the SAM created for it? The folder contains several supporting files and the API itself that the script needs to run.
You might try searching this forum for "python" -- there are a few discussions that might help you troubleshoot.
Best regards,
Paul.
You can access the SAM application programming interface (API) from scripts or programs you write in various languages. The SDK provides everything you need to do that, so you don't need SAM to run the simulations once you have your environment set up.
It's a good idea to generate code from a case in SAM as you did because that automatically creates a ready-to-run script or program that you can start from.
Are you running the Python script from the folder the SAM created for it? The folder contains several supporting files and the API itself that the script needs to run.
You might try searching this forum for "python" -- there are a few discussions that might help you troubleshoot.
Best regards,
Paul.
Please Log in or Create an account to join the conversation.
Moderators: pgilman