🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Optistruct automation

User: "Rachit Semalty"
Altair Community Member
Updated by Rachit Semalty

Hi all. I am working on an automation project. I want to kill an optistruct run. May I know what is the command to kill an optistruct run from python or tcl, or both if possible? Also, please note that there might be more than one optistruct run running simultaneously. So I want to kill just one of them and not all. 

Please help ASAP.

Regards,

Rachit

Find more posts tagged with

Sort by:
1 - 14 of 141
    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    I'm not sure if there is a specific way to kill a job like this, if you can write to the run directory though, you can create the file in the run folder with name <JOBNAME>.osquit (e.g. if the output file is my_run.out then this file should be my_run.osquit). Content of the file is irrelevant, it may be empty. That should stop the job.

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    I'm not sure if there is a specific way to kill a job like this, if you can write to the run directory though, you can create the file in the run folder with name <JOBNAME>.osquit (e.g. if the output file is my_run.out then this file should be my_run.osquit). Content of the file is irrelevant, it may be empty. That should stop the job.

    Hi Paul. Thanks for your reply. I did create a .osquit file with name of current run but it did not kill the run. First I made a text file with name <my_current_job_name>.osquit. That did not work. Then I made a .osquit file with name <my_current_job_name>.osquit. But that too didn't work. May you please tell me if I am wrong anywhere?

     

    Regards,

    Rachit

    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    Hi Paul. Thanks for your reply. I did create a .osquit file with name of current run but it did not kill the run. First I made a text file with name <my_current_job_name>.osquit. That did not work. Then I made a .osquit file with name <my_current_job_name>.osquit. But that too didn't work. May you please tell me if I am wrong anywhere?

     

    Regards,

    Rachit

    Not sure what is happening for you, I just tested again in latest version as I have not used it in a long while, and it worked fine, the file needs to be in the running directory of the job, i.e. below I created optimisationrun.osquit (empty file) and the model run stopped within a few seconds.

    image

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    Not sure what is happening for you, I just tested again in latest version as I have not used it in a long while, and it worked fine, the file needs to be in the running directory of the job, i.e. below I created optimisationrun.osquit (empty file) and the model run stopped within a few seconds.

    image

    Hi Paul. I made a file like this:

    image

    And also like this:

     

    image

    But none of them worked. I am using 2017 optistruct solver and not compute console. Also, my analysis is NLGEOM. Are you able to identity any mistake I may be making?

     

    Regards,

    Rachit

    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    Ah, I think maybe you have file extensions hidden in windows? It looks like what you may have done is create a file called FileName.osquit.txt and a file called FileName.osquit.osquit neither of those will work

    It should just be FileName.osquit

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    Ah, I think maybe you have file extensions hidden in windows? It looks like what you may have done is create a file called FileName.osquit.txt and a file called FileName.osquit.osquit neither of those will work

    It should just be FileName.osquit

    Hi Paul. Thanks for your quick reply. Yes I had file extensions hidden. Now I checked show file extension option and have created the following file:

    image

    But it still does not work. Is any other error possible?

     

    Regards,

    Rachit

    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    Can you share a sample model? Maybe there is something specific in your case, I have run a couple of test cases and osquit works for me each time.

     

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    Can you share a sample model? Maybe there is something specific in your case, I have run a couple of test cases and osquit works for me each time.

     

    Yes sure.

    User: "PaulAltair"
    Altair Employee
    Accepted Answer
    Updated by PaulAltair

    Ah, ok, I see what is happening here, you are running the old NLGEOM subcase type, in this subcase the job is running Radioss, and OS is kind of suspended while this happens, to kill the subcase, in your case you can create a file Trial_Analysis_01_rad_s1_0001.ctl with the contents /KILL, then the osquit file Trial_Analysis_01.osquit will terminate the OS bit. In more recent versions of OS, I would suggest using a LGDISP subcase in place of NLGEOM.

     

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    Ah, ok, I see what is happening here, you are running the old NLGEOM subcase type, in this subcase the job is running Radioss, and OS is kind of suspended while this happens, to kill the subcase, in your case you can create a file Trial_Analysis_01_rad_s1_0001.ctl with the contents /KILL, then the osquit file Trial_Analysis_01.osquit will terminate the OS bit. In more recent versions of OS, I would suggest using a LGDISP subcase in place of NLGEOM.

     

    Thanks for your reply. Yes it worked for my case. We will consider using LGDISP subcase in place of NLGEOM subcase.

     

    Regards,

    Rachit

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    Ah, ok, I see what is happening here, you are running the old NLGEOM subcase type, in this subcase the job is running Radioss, and OS is kind of suspended while this happens, to kill the subcase, in your case you can create a file Trial_Analysis_01_rad_s1_0001.ctl with the contents /KILL, then the osquit file Trial_Analysis_01.osquit will terminate the OS bit. In more recent versions of OS, I would suggest using a LGDISP subcase in place of NLGEOM.

     

    Hi. I want to ask one more question. After killing the run, steps files are converted to .rst file and then to .h3d files. Is there any way I may stop this conversion as this causes memory issues sometimes?

     

    Regards,

    Rachit

    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    the rst files and the h3d creation by hvtrans are both as a result of the NLGEOM (radioss) subcase, there is nothing you can do to stop them, the rst are not turned into h3d, it is the Annn files that are converted

    User: "PaulAltair"
    Altair Employee
    Updated by PaulAltair

    attached is a running example for LGDISP (Non linear geometry in Optistruct, natively), I was able to run it in v2022

    User: "Rachit Semalty"
    Altair Community Member
    OP
    Updated by Rachit Semalty

    attached is a running example for LGDISP (Non linear geometry in Optistruct, natively), I was able to run it in v2022

    Thanks for your help. It was helpful.

     

    Regards,

    Rachit