Jump to content

Create multi-layered asset tree from csv file.


Recommended Posts

  • Seeq Team

TLDR

Asset trees are great way to scale your analysis to N number of assets.  Currently one needs working knowledge of SPy(Seeq-python) to build multi layered asset tree.  With the attached jupyter notebook, Add-on tool can be created as shown here so that users can generate their own multi layered asset trees in their workbenches which can then be shared with colleagues.

Pre-Requisite: Seeq Data Lab (powered by SPy module)

Detail steps:

1. Get a CSV file (can be done in excel and saved as CSV format) that has hierarchy of your asset tree structure.  The columns in screenshot below represent various hierarchical levels (columns A,B,C &D). You don't need exactly 4 columns, the solution supports any number of columns/hierarchical levels.  

2. Include a column for "Process Value" (column F in screenshot below) which are your tag values and a column for "Asset Tree Name" which will appear in the tree and are the common attribute names among assets (column E in screenshot below).

image.png

3. Use the attached jupyter notebook and create Add-on tool so any user can access the tool from Tools pane in workbench. This is one time step and should be done by someone who has experience with Seeq Data Lab.  The Tool name can be "Create Asset Tree from CSV File". Here is KB article on setting up new Add-on tool. https://seeq.atlassian.net/wiki/spaces/KB/pages/961675391/Add-on+Tool+Administration+and+Development

4. Use attached csv file and have your colleague who knows nothing about python, run the tool.  UI is self explanatory as seen below.

image.png

5. Refresh the workbench from which user created the Asset Tree and watch the results appear like so: 

image.png

Optional step 6: If there is no Add-on tool available, or you would like to build it step by step then add calculations, roll ups etc., check out the jupyter notebook named step_by_step_asset_tree attached below.

Example_SDL_Asset Tree (1).csv

Create_asset_tree_with_dynamic_class_attributes.ipynb

 

Step_by_step_asset_tree.ipynb

  • Like 1
  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...