找回密码
 注册
Simdroid-非首页
查看: 287|回复: 0

【分享】How do I submit a job to a queue in ABAQUS/CAE?

[复制链接]
发表于 2003-8-7 13:33:03 | 显示全部楼层 |阅读模式 来自 日本
给大家来个好东东-英文的。
  
(The following applies to ABAQUS Versions 6.2 and later.)
  
When you configure a job, you can request that ABAQUS/CAE route the job to a specified queue on a remote UNIX host computer. You can specify the remote queue by selecting an associated queue name in the Submission page of the Edit Job dialog box.
  
Each queue name that appears in the Edit Job dialog box refers to an entry in your ABAQUS environment file in which you specify how you want the job to be run on the host computer. In other words, when you select a queue name in the Edit Job dialog box, you specify not only the desired queue on the host computer but also other options, such as the directory on the host computer in which you want to run the job and the files you want copied back to your local directory when the job is complete.
  
You can specify your preferences for running a job remotely by adding the following functions to your ABAQUS environment file:  
  
def onCaeStartup():
    import os
    from abaqus import *
    
    def makeQueues(*args):
        session.Queue(name,
                      queueName,
                      hostName,
                      fileCopy,
                      directory,
                      driver,
                      localMachineType,
                      remoteMachineType,
                      filesToCopy,
                      description)
    
    addImportCallback('job', makeQueues)
  
The following list describes each argument in the session.Queue method:  
  
name: The queue name that you want to appear in the job editor.  
queueName: The name of an existing queue definition defined in your environment file. See Submitting job to batch queues  
  
hostName: The name of the host computer. The default is the name of the local computer.  
  
fileCopy: When the analysis is complete, the value of this argument determines whether or not the analysis files will be copied back to the directory from which the job was submitted. The default value is OFF.  
  
directory: The name of the directory on the host computer where you want the job run. You must have write privileges to this directory. The default is the local directory (the directory from which you are submitting the job).  
  
driver: The name of the command on the host computer to execute ABAQUS/Standard or ABAQUS/Explicit. The default is abaqus.  
  
localMachineType: The platform on the local computer. You can specify either UNIX or NT (for Windows); UNIX is the default.  
  
remoteMachineType: The platform on the host computer. You can specify either UNIX or NT (for Windows); UNIX is the default.  
  
filesToCopy: The three-letter extensions of the analysis files that you want copied back to the local directory when the job is complete. By default, the files with the following extensions are copied: .log, .dat, .msg, .sta, .odb, .res, .abq, and .pac.  
  
Note: The restart (.res) file, the ABAQUS/Explicit state (.abq) file, and the packaging (.pac) file are platform-dependent; if your localMachineType and remoteMachineType settings differ, you will not be able to copy and use these files to restart an analysis. All of the other files listed above can be copied across platforms without any difficulty.  
  
description: A short description of the queue.  
  
The name and queueName arguments must be included in each queue definition. However, if you do not include any of the other arguments in a queue definition, default values will be supplied automatically. An example queue definition is shown below:  
  
def onCaeStartup():
    import os
    from abaqus import *
    
    def makeQueues(*args):
        session.Queue(name='long',
                        queueName='aba_long',
                        hostName='jobserver',
                        directory='/scratch/' + os.environ['USER'])
    
    addImportCallback('job', makeQueues)
  
The commands in the example above configure the following:  
name: The queue name displayed in the job editor is long.  
  
queueName: The queue name on the host computer is aba_long.  
  
hostName: The name of the host computer is jobserver.  
  
directory: The directory on the host computer where ABAQUS will store the input file and all other files associated with the job is /scratch/your user name.  
  
Since the fileCopy, driver, localMachineType, remoteMachineType, and filesToCopy arguments have been left out of the entry above, the default options for these parameters are assigned to this queue automatically.  
  
If you want to create two or more queues, you can repeat the line containing the session.Queue command as many times as necessary. For example, the following ABAQUS environment file entry specifies two queues, one named long and the other named job:  
  
def onCaeStartup():
    import os
    from abaqus import *
    
    def makeQueues(*args):
        session.Queue(name='long',
                        queueName='aba_long',
                        hostName='jobserver',
                        directory='/scratch/' + os.environ['USER'])
        session.Queue(name='job',
                        queueName='aba_job',
                        hostName='jobserver',
                        fileCopy=OFF)
    
    addImportCallback('job', makeQueues)
  
希望大家把自己的使用技巧尽量POST出来,可以考虑适当加分的。为了国际接轨,最好用英文。谢谢。

评分

1

查看全部评分

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|小黑屋|联系我们|仿真互动网 ( 京ICP备15048925号-7 )

GMT+8, 2024-7-1 22:08 , Processed in 0.046011 second(s), 16 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表