Jump to content
  • Accessing PI Data in Spotfire


    This article explains what the OSISoft PI System does and how Spotfire can access the data for further processing and analysis.

    What is OSISoft PI System?

    OSISoft Data Archive or sometimes called the PI system is a set of tools to collect and organize time series data from different data sources. This data will be accessed later on using tools like Spotfire for further processing and analysis. Some use cases include

    • Seasonal trends analysis
    • Causality study
    • Variables modeling and prediction
    • Process optimization

    here is a schema that explains different components of the OSISoft tools and how are they connected to each other.

    pi_system_simplified.png.d4f87591b23645defc6edc8c2daa1f54.png

    Connect to PI Data Archive in Spotfire

    Spotfire PI Connectors provide two ways to connect to OSISoft data:

    Using the GUI connector

    • From the + sign in Spotfire left panel choose (Other --> OSISoft PI Server Tag Data)

    pi_data_access_in_spofire_gui.png.50d7d94abe2a8707d5f1d7ecc20659a8.png

    Once you select Tag Data, the connection GUI will show as below:

    pi_data_access_in_spofire_gui_0.png.73e5a713aa51486ee72004d357fb57dc.png

    Fill in the details and make sure you use the suitable authentication method, click Connect and move to the Tag Selection tab.

    In this tab you select the tag/tags you need to include in your query, wild cards are allowed here, for example, we want to look for tags that have power production. Once the search is complete, simply select the tags and click Add to include them in the query.

    pi_data_access_in_spofire_gui_1.png.639a025a1ee50f9244f57ed23b336120.png

    Once adding tags is complete, click on the Data Retrieval tab. 

    In this tab you specify how you want to bring your data, options in Retrieval Mode  are:

    • Actual Values ? returns only actual recorded data points. This mode can only be used with Tags that return numerical data.
    • Interpolated Values ? returns data interpolated to produce the requested number of points. This mode can only be used with Tags that return numerical data.
    • Plot Values ? returns data enhanced to look good on a chart plot.
    • Snapshot ? returns the current Snapshot value of the Tag data.
    • Total, Average, Minimum, Maximum, StdDev, PopulationStdDev, Count, PercentGood ? these options calculate values for each summary.

    More details about the Data Retrieval can be accessed through the PI Connector manual

    Once everything is complete, click OK  and Spotfire will create a new data table for the query.

    Using Custom data function

    Using data functions in OSIPI is a great way to have more control over how you pull the data from Data Archive and also give more flexibility to dynamically change and update query parameters. Custom data functions can be accessed via Tools----> Create Tag Details View and the custom data function dialogue will appear as below:

    1_41.thumb.png.1ab8ac08ee83008b3bd6b4fddd9cff67.png

    2_20.thumb.png.0ecc142839e57650ee5f9fab44c34d25.png

    • Server: OSIPI Server name
    • Username, Password, Encrypted, Domain, Authmode: Leave them unchanged if you have set up your mode to be Windows Integrated.
    • Tag Name:  PI Tags that needed to be queried from the database, user can use custom expressions, and Spotfire tables to provide a list of tags. For instance, you can upload an excel sheet that has all the needed tags and use that as input.
    • Retrieval Mode: Similar to the option explained above, it's basically choosing how you want to bring the data
    • Calculation Basis: Defaulted to Time Weighted and can be changed to be event-based. 
    • Summary Duration: The aggregation window the OSIPI should use to prepare the data (Default is the 60s)
    • Start/End time: There are several useful ways to use a wildcard to set a specific start/end time. Consult the OSIPI manual for more details.

    Connect to Asset Framework (AF) server in Spotfire

    Using the GUI connector

    Using the GUI of the AF connector in Spotfire is pretty straightforward.

    af.thumb.png.6796b3e814927673d3a5accb6321985e.png

    The AF GUI dialogue box will open:

    1_43.thumb.png.9dbdc1369aa8c86004271391de3d1d92.png

    • If you are using Windows Auth. you don't need to fill in the username and password. 
    • Click connect and move to the Elements and Attributes tab

    2_22.thumb.png.24726f6aad557818ed7b295df1acee30.png

    • This is the most important dialogue in AF GUI.
    • Left side is where you choose the elements that you want to query (Motors, Pumps, etc) no tags are selected here. Say we want to include only motors from the specific station in this query then all you need to select these elements and press the down arrow to include it
    • Right side is where you select your parameters for these elements, say we want to bring all the values for the current variable for all the motors, then all you need to select the variable and press the down arrow to include it
    • Click Ok and check the resulting table

    Below is a sample table of the output.

    3_23.png.458363615a137a0fd1c700ab59ad86f7.png

    You can see that only selected Elements and Parameters were brought as tags, you can then join this table to your tag data table and use it as a filtering feature.

    For more information, watch this session of Dr. Spotifre as we go through the OSIPI connector in Spotfire in detail.

     

    • Like 1

    User Feedback

    Recommended Comments

    There are no comments to display.


×
×
  • Create New...