[PyAEDT][PyAnsys] How to use submit_job function to work with Ansys Cloud

Odysseas
Odysseas Member Posts: 2
First Comment

Hello, I am looking for some help regarding submitting jobs via PyAEDT/PyAnsys to the Ansys Cloud.

There is an issue with the command Hfss.submit_job (found here). Firstly, the arguments are not well defined (for example clustername is only defined as string, not the correct inputs for this string, any one know what correct inputs would look like?) in the documentation. Secondly, looking at the source code (script desktop.py) we saw that there are also other arguments that are not even mentioned in the documentation, like project_file. There are also no traceback errors calls to help. Here is the small code we have:

from pyaedt import Hfss

hfss = Hfss(r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt")

hfss.submit_job(project_file = r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt", clustername = "ansyscloud", aedt_full_exe_path = r"C:\Program Files\AnsysEM\v231\Win64\reg_ansysedt.exe",setting_file = r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Submit_Job_Settings_ANSYS_CLOUD_with_server.areg")

 


PyAEDT ERROR: Method arguments:

PyAEDT ERROR: project_file = C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt

PyAEDT ERROR:    clustername = ansyscloud

PyAEDT ERROR:    aedt_full_exe_path = C:\Users\OVotsis\Downloads\Incident Wave Excitation.aedt

PyAEDT ERROR:    numnodes = 1

PyAEDT ERROR:    numcores = 32

PyAEDT ERROR:    wait_for_license = True

PyAEDT ERROR:    setting_file = C:\Users\OVotsis\Downloads\Submit_Job_Settings_CLOUDss.areg

PyAEDT ERROR: Check Online documentation on: https://aedt.docs.pyansys.com/version/stable/search.html?q=submit_job+project_file+clustername+aedt_full_exe_path+numnodes+numcores+wait_for_license+setting_file

False

If anyone has experience with the submit_job function for use with Ansys Cloud your help would be greatly appreciated. Also it there is any other way of using PyAEDT to submit a job to the cloud please let me know. Thank you for your time

Best Answer

Answers

  • Odysseas
    Odysseas Member Posts: 2
    First Comment
    edited June 23

    Hello, I am looking for some help regarding PyAEDT and job submission to the Ansys Cloud

    There is an issue with the command Hfss.submit_job (found here). Firstly, the arguments are not well defined (for example clustername is only defined as string, not the correct inputs for this string, any idea what will those be?) in the documentation. Secondly, looking at the source code we saw that there are also other arguments that are not even mentioned in the documentation, like project_file. There are also no traceback errors calls to help. Here is the small code we have:

    from pyaedt import Hfss

    hfss = Hfss(r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt")

    hfss.submit_job(project_file = r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt", clustername = "ansyscloud", aedt_full_exe_path = r"C:\Program Files\AnsysEM\v231\Win64\reg_ansysedt.exe",setting_file = r"C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Submit_Job_Settings_ANSYS_CLOUD_with_server.areg")


    This makes the following error:

    PyAEDT ERROR: Method arguments:

    PyAEDT ERROR: project_file = C:\Users\OVotsis\Downloads\Incident Wave Excitation Folder\Incident Wave Excitation.aedt

    PyAEDT ERROR:    clustername = ansyscloud

    PyAEDT ERROR:    aedt_full_exe_path = C:\Program Files\AnsysEM\v231\Win64\reg_ansysedt.exe

    PyAEDT ERROR:    numnodes = 1

    PyAEDT ERROR:    numcores = 32

    PyAEDT ERROR:    wait_for_license = True

    PyAEDT ERROR:    setting_file = C:\Users\OVotsis\Downloads\Submit_Job_Settings_CLOUDss.areg

    PyAEDT ERROR: Check Online documentation on: https://aedt.docs.pyansys.com/version/stable/search.html?q=submit_job+project_file+clustername+aedt_full_exe_path+numnodes+numcores+wait_for_license+setting_file

    False


    If anyone has any idea about how to properly set arguments on the submit_job function it would be of great help. Also if there are any other ways to submit a job to the Ansys cloud via PyAEDT please let me know. Thank you for your time!