You are on page 1of 30

3DS.COM © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.

: 3DS_Document_2015

for Developers
Pipeline Pilot Tips and Tricks

Eddy Vande Water


Eddy.vandewater@3ds.com
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

2
Overview

REST Services

Other Tips & Tricks


Publishing Protocols

Component Creation
Publishing Protocols – Web Port
 Publish Protocols to Protocols/Web Services
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Promote Parameters to Top Level

 Optionally create input forms

3
Publishing Protocols – Web Port
 Direct link to protocol in the help text
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Launches that protocol in Protocol tab

 Folders can be assigned to groups/users

4
Publishing Protocols – Direct Link
 Right click on a protocol
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

to Create Protocol Link

 Set results to desired


return option
 Show All Results
 Show File Result
 Run in Web Port

 Can also run


anonymously

5
Publishing Protocols – REST services
 Representational State Transfer (REST)
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Pipeline Pilot protocols can be published as REST services

 Can utilize URL routing to simplify requests

6
REST Services – Creating a Package
 Create a package using pkgutil
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Add appropriate URL tags to properly route

 Install the package

 Restart service

7
REST Services – Passing Parameters
 Parameters can be
3DS.COM © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

passed:
 URL arguments

 Passed parameters

8
REST Services – Documentation
 Documentation added using <meta> tags in package.conf
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 APIdoc available at http://<server>:<port>/apidocs

9
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

10
Publishing Protocols – REST guide
Validating Protocols
 Validation rules can be written for protocols
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Manual validation through Tools->Validate Protocol

 Automated validation can be set up by admins

 Validation protocols found in Protocols/Utilities/Validation/Protocol Validation


Rules (Default)

11
Creating your own components
 Components can be created using other languages
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Can execute the following languages:


 .NET

 C#

 Perl

 Python

 VBScript

12
Creating your own components
 Create three methods:
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 onInitialize

 onProcess

 onFinalize

 Pipeline Pilot passes globals (context) and data record properties

13
PilotScript Flow Control – Older Method
 Custom Filter is required upstream of Custom Manipulator to handle missing data
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

14
PilotScript Flow Control
 The function DataSetPort(#) allows to control the flow of data record
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

0 – discard
1 – pass port
2 – fail port
 All logic in one place!

15
PilotScript Flow Control
 Problem: no simple way to return
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

‘summary’ information from Custom


Manipulator
 e.g.,
a count of failures in previous
example

 Answer: Use DataSetPort in


Final Expression!

16
Initialize Using…
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Dynamic selection of parameter


values

 Right-click on most parameters

 Options change based on context

18
Avoid Sending Files
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Paste text into your protocol to


reduce files

 Write data to a delimited text file

 Copy/paste data to the protocol

 Can use Delimited Text Text


Reader or Initialize Using…

19
Highlighted Keyboard Shortcuts
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

Keypress Action
Ctrl + M Toggle Maximize View / Normal View
Ctrl + Shift + B Curved / Bent Pipes
Ctrl + Shift + I/P/F Toggle Input/Pass/Fail Ports
Alt + Double Click Open Expression Editor
Shift + Double Click Edit Component Parameters
Ctrl + Double Click Step out of Subprotocol

20
Local Shortcuts
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Problem
 You are using a subprotocol multiple
times in a protocol and want to make
changes in a single place
 Subprotocol only relevant for this
protocol
 Solution
 ‘Local Shortcuts’ – exist only in the
protocol. Updating any copy will cause
all versions to be updated.

21
Shortcuts
 Problem: You don’t know prior to run time what component you will need.
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Solution: Shortcut component!

22
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

24
Jobs window.
Job Results Recovery

 Never fear! Recover results from the


3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

25
Reduce Branching

Branching Duplicates Data


Use Caches to Avoid Branching
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Cache / Temporary File to reduce


memory usage

 Improve performance / debug


capabilities

26
When and Where to Calculate Properties
 Think about the order you need to do things
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Compared with…

27
Component Profiling
 Identify protocol bottlenecks
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Ctrl+T to toggle between options


 Absolute compute time (sec)
 Percentage of total execution time

28
Debug Messages
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Provides a method to debug


protocols at run time
 Displays messages in the Debug
Messages window
 (View->Debug Windows -> Debug
Messages)
 Debug Parameters Window to
include Pass/Fail port messages

29
New Dashboard Collection
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

 Dashboard software for non-techies


 Build modern HTML5 responsive
web reports and dashboards
 Mobile-enabled
 Cross-platform
 Variety of chart types, maps, tables,
grids and lists
 Drill-downs
 Embedded rich media
 Interactive charts: zoom, mouse over
tool-tips, series toggle
30
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

31
Your tips and tricks?
3DS.COM/BIOVIA © Dassault Systèmes | Confidential Information | 6/14/2017 | ref.: 3DS_Document_2015

32

You might also like