
- #ORCAFLEX BATCH POST PROCESSING INSTALL#
- #ORCAFLEX BATCH POST PROCESSING SOFTWARE#
- #ORCAFLEX BATCH POST PROCESSING CODE#
- #ORCAFLEX BATCH POST PROCESSING FREE#
This tutorial walks through a Python example of running a parallel workload using Batch. import os, re for root, dir, file in os.walk(/path/to/files): for f in file: if re.match('.*\.dat$', f): run_existing_script1 root + / file run_existing_script2 root + / fil Use Azure Batch to run large-scale parallel and high-performance computing (HPC) batch jobs efficiently in Azure.

#ORCAFLEX BATCH POST PROCESSING CODE#
You may then open Notepad and copy the code below You can write a batch script in python using os.walk() to generate a list of the files and then process them one by one with your existing python programs. For demonstration purposes, I created a simple batch file that would produce The Matrix effect, but the method described here would work for any batch file that you'd like to run from Python. Calculate the relative velocity & log extremes.Steps to Create a Batch File to Run Python Script Step 1: Create the Python Script Step 2: Save your Script Step 3: Create the Batch File Step 4: Run the Batch Fil Steps to Run a Batch File from Python Step 1: Create the batch file. Slide #User Group, 2013Python Automation8Example#2: Post-ProcessingThe task we want Python to do is: -At each sample time:Get the Crane Tips GZ-Velocity, X and Y results.Use the X and Y results to get the Environment's Z-Velocity. =large batch script table.Slide #User Group, 2013Python Automation7Įxample#2: Post-ProcessingUsed to extract complex results: Slide #User Group, 2013Python Automation6Įxample#1: Pre-ProcessingVariables:Wave & current directionsWave period (& stage durations)Vessel initial X & Y positionVessel heading7x line sections line types to change Slide #User Group, 2013Python Automation5Įxample#1: Pre-ProcessingThis example:8x weather directions2x wave periods2x conditions (SOL & EOL)2x vessel offsets (moorings intact & one line broken)=64 load cases Slide #User Group, 2013Python Automation4Example#1: Pre-ProcessingUsed to efficiently generate multiple load casesExcel vs Python exampleParticularly useful when there are decisions to be made as part of the automation processSuper-quick when changes are required Slide #User Group, 2013Python Automation3Typical UsesFour key ways to use Python with OrcaFlex:Pre-processingPost-processingAs an optimization / parameter study toolAs an External Function
#ORCAFLEX BATCH POST PROCESSING FREE#
Why Python?Scripting language, automatic compile stepClean synta圎asy to learnComprehensive standard libraryWell documentedIts free We recommend using the Python or MATLAB interfaces for automation and scripting tasks. You can also link to it using other languages, with a bit of extra work. You can link to the DLL using programing languages such as Python, MATLAB, C++ and Delphi. This means being able to set data items, run simulations, extract results etc. So you can use the API to drive OrcaFlex from outside of the User Interface. The programming interface provides a doorway into OrcaFlex, through which you can pass data.
#ORCAFLEX BATCH POST PROCESSING INSTALL#
OrcFxAPI is a Windows dynamic link library (DLL) that is installed when you install OrcaFlex. To cater for this, OrcaFlex comes with a programming interface, called OrcFxAPI (short for OrcaFlex Application Program Interface). In addition, some OrcaFlex users simply dont want to use the spreadsheet for a variety of reasons. There are some tasks that you just cannot do with the spreadsheet.

However as good as the spreadsheet is, we recognise that it has some limitations. It is a robust, efficient, easy to use option that is, and will continue to be, the primary automation facility that we promote for use with OrcaFlex. For those of you that use the spreadsheet extensively, there is nothing wrong with using this method.
#ORCAFLEX BATCH POST PROCESSING SOFTWARE#
This spreadsheet is supplied with the software and is set up with in-built macros to make your pre and post processing tasks more efficient and less error prone.

Slide #User Group, 2013Python Automation2Whats it all about?The first option most people think of when it comes to OrcaFlex automation is, not surprisingly, the Excel spreadsheet. IntroductionSession aimed at demonstrating Python being used for OrcaFlex automation:Whats it all about? Typical UsesWhy Python?Examples of:Pre-processing, Post-processingDesign OptimisationSlide #User Group, 2013Python Automation1Whats it all about?A means to efficiently automate tasks:Excel Spreadsheet = 1st choice for most tasksOrcFxAPI OrcaFlex Application Program InterfacePython, MATLAB, C++, Delphi
