Selafin File QGIS-Plugin v2: Reads OpenTELEMAC binary files!

QGIS made a big step forward during the last 2 years, it is meanwhile an outstanding tool to display spatial data like Telemac results on maps and in atlases.

It provides access to several hundred postprocessing tools, which are already connected to QGIS: GRASS, SAGA, R Statistics and many others.

1more

Updated FEATURES of Version 2.0r2 (2015-09-01)

  • Some Bug fixes
  • Now accepts corrupt BlueKenue files with illegal IPOBO array
  • Selection window now scales better for very large number of datasets

New & Updated FEATURES of Version 2.0 

  • Now reads TELEMAC 3D (NEW) and 2D binary files!
  • Keeps georeference via EPSG Code (NEW), which is saved in the SELAFIN file after using the “SHIFT” function.
  • Buttons to switch between time steps after loading (NEW)
  • Reads Boundary Condition files (CONLIM / CLI)
  • Infoscreen during loading (This is the price you have to pay for using the tool for free)
  • Displays:
    • Datasets as Triangles with HillshadeQGIS_mesh+shade
    • Boundary ConditionsQGIS_CLI
    • Datasets as VectorsQGIS_vec
    • Displays Selafin files as rasterized GRID (NEW!). This option is a linear regular grid interpolation of the irregular triangulated network (TIN).  It provides a much better visual interpretation than the irregular nodes. Click on the following gallery:

       

       

       

       

       

       

       

       

       

       

       

    • Displays Selafin files as VORONOI Diagram (NEW!) (perfect option for Sisyphe!) Especially the SISYPHE files have to be interpreted not as triangles, but as volume where every place has the properties of the closest network points. Click on the following pictures to see the difference: The Voronoi polygons are colored by the untouched mesh point values, while the triangles are colored by the mean values of their 3 points.

       

       

       

       

       

       

       

       

       

       

  • Allows filtering of the attributes to load
  • Tested with > 1 000 000 Elements

 

USAGE

The Plugin brings 4 new buttons for the toolbar. All functions are available from the Menu Bar as well. Left to right: “LOAD”, “HELP”,”SHIFT”, “AUTOCOLOR”.

Bildschirmfoto-2

  1. Load files
    • Pressing the “LOAD FILE” Button – > Choose a File
    • The “Choose datasets” window opens:
      2D: Choose some datasets in the “Time / Variable” Matrix and choose the display optionsSelector3D: Choose the Layer of the 3D dimension to display (e.g. “1” for “Bottom”, …, “Topmost” for “Free Surface”), QGIS is plain 2D and cannot display the full files in 3DChoose_datasets
    • Select how you want to display the Mesh: as Triangles or Points, with Hillshade, with surrounding Polygon, with an additional CONLIM Boundary file
    • Select the datasets to be displayed. Keep in mind: the more you choose, the slower your display.
    • (If you choose “Append Boundary (CONLIM)” a second file dialog opens to choose this file)
    • The Coordinate System Dialog shows up. Choose the right one, the one your original data was delivered with. If in doubt, choose a metric system, but no Mercator or Geographic System.Koordinatenbezugssystem
    • Finally the mesh is loaded and displayed. The “Layer Menu” shows a group with up to 5 layers. All based on the same Selafin file. Find options and metadata in the layer properties menu.Bildschirmfoto-3
    • ATTENTION: The displayed data is unsaved. You can change anything in QGIS, it will not be written back to the original file. Save changes in any vector data format.
  2. Colorize features
    • Directly after loading the data, some proper layout and coloring is assumed. Feel free to change it to what ever layout you prefer.
    • The “AUTOCOLOR” button gives you a fast access to some predefined styles. (Currently available for “Triangles”, “Points” and “Hillshade” layers)
    • Use the property menu of the layers to change the layout manually. e.g.
      • by hand.
      • by predefined style files “.qgs” : some are placed in the plugin folder.
      • by data depended symbol options. This powerful option is used e.g. to display vectors and symbol size. This menus are difficult to find. Use the following picture to walk deep through the option dialogs.Bildschirmfoto-4

 

FAQ

  1. I found a bug ….
    • Please contact us!
  2. Loading Speed & Multiprozessor Setup
    • File loading will take some time depending on your QGIS and Hardware. Currently it takes 12 seconds on my computer to display the full example case “221_donau” which you find in the plugin folder. It takes 54 seconds for a project with 660 000 points with 12 attributes, and hill shading.
    • Most of the time is consumed by QGIS by indexing the new data.
    • You can speed up the display time by activating multiprocessor support for QGIS (Options -> Display), which is not activated by default. See HERE.
  3. No velocity vectors visible
    • Problem 1: your layer style definition was made with time step reference and the current layer has a different time step … Just change this attribute names in the style definition
    • Problem 2: They are probably to small to be visible, this normally means, that you have no velocity or you choose a non metric coordinate system (Lat/Lon, Geographic) which degrades the metrical vector length to invisibility.
    • SOLUTION A: Switch to the right coordinate system
    • SOLUTION B: Create your own suitable vector style by using the data depended formatting options.
      • Symbol: Any
      • Rotation: ATAN2(“velocity x”,”velocity y” ) / PI *180
      • Size: ((“velocity x”)^2+(“velocity y”)^2)^0.5 * “Custom Magnification Factor”
  4. Save As …
    • Option 1 (more or less outdated): The loaded layers are not saved by default any more as shapefile. It is up to you, if you save them. If you want to save the whole QGIS project with layout and format, you have to save the SELAFIN file to a GIS format first.
    • Option 2 (comfortable, as you don’t have to think about anything): use the “Memory Layer Saver”-Plugin (you’ll find it in the plugin manager). It makes unsaved layers persistent so that they are restored when a project is closed and reopened. The LAYER STYLE is saved in the project file. The MESH DATA is saved in a portable binary format (QDataStream) that is saved with extension “.mldata” alongside the project file. Advantage: you can just click on the project file in the browser to reopen the project and it looks like the last time. Disadvantage: It duplicates the data for each view perspective …
  5. Where are all the fancy post processing tools from SAGA, GRASS, R, ORFEO etc.
    • Some versions of QGIS need to activate this tools separately: http://docs.qgis.org/2.6/en/docs/user_manual/processing/3rdParty.html?highlight=saga
    • Bildschirmfoto-5
    • The right side toolbar in this picture shows the “Processing” tools.
  6. Model on wrong place / Problems with georeferencing
    • One common error is: you choose the wrong coordinate system on startup. The right coordinate system is the one of your mesh original data. Commonly its a “Metrical” Projected Coordinate System, not a Mercator or Geographic Coordinate System.
    • The other common error might be due to the mesh generators usual error not to save the X_ORIGIN , Y_ORIGIN in the SELAFIN files. Blue Kenue and Janet do not probably care for that issue, as it is not relevant to flow calculations.
    • SOLUTION for the second error: I implemented a simple function to shift the model with 2 clicks:
      • Select the layer to be shifted
      • Use the “SHIFT Selafin file” button from the toolbar. The mouse pointer turns into a crosshair cursor.
      • Click on a point of the mesh which is in the wrong place
      • Select the place where it should be. The layer should be shifted to that place.
      • Repeat
      • Deselect “SHIFT Selafin file” button
      • (Known issues: Problems with non metrical coordinate systems)
  7. Further help via Email or -> in my 2015 training sessions.mail_tel

LICENSE & COST

The current version is freeware and comes “as it is” without any warranty. Redistribution and modification can be granted after individual negotiation. Since Version v2 during loading time a splash screen displays various pictures with informations (updates, user training, etc.) about UHM River Engineering. The pictures are downloaded every now and then via internet from our website. Enduring advertisement is the price you pay.

2015-06-22: Update after confusing emails: 

The source code is our own development, based on the documentation of OpenTELEMAC and QGIS and can be obtained for free for everybody who needs it, as guaranteed through the inherited QGIS GPL license. The main reason why we don’t distribute the source code with the download is: almost nobody needs it, and the few who need it will have to contact us for explanation anyway. Then they will obtain the newest version for free, and optional individual adaptations. We keep in contact with the other developers to the benefit of improvements.

UPCOMING DEVELOPMENTS

This plugin is a niche product, interesting for only a few hundred users world wide. Even though Telemac, QGIS, Paraview etc. are free, this plugins development is driven by individual demands. If somebody needs a feature it can be added against payment. As the general interest in new features is high and the development costs as well, I propose a cost sharing by going commercial with future versions of this tool. You can give me a hint, if it is worth spending more time on this by writing an email.

DOWNLOAD

The plugin is free. To reduce the traffic of our website access is limited to registered users. Please fill the following form to get access to the current plugin version. An Email will arrive within seconds in your mailbox, which contains all necessary information.

BY DOWNLOADING, YOU ACCEPT QUALITY, LICENSE AND WARRANTY AS IT IS.

 

 

 

 

 

For special wishes or in case of problems with the registration contact me via email or phone:

mail_tel

INSTALL

  1. Copy the content of the archive to
    • Linux: /home/[username]/.qgis2/python/plugins/ 
    • Windows XP, 7, 8: C:\[users]\[username]\.qgis2\python\plugins\
    • Mac: Unofficial & untested, but several users confirmed it is working. The “.qgis2/python/plugins/” folder is in different places, you have to use the search functions.
  2. Start QGIS
  3. Open “Plugins –> Manage and Install ..” and activate the “Telemac / Selafin Reader” by checking it in the list of plugins.Screenshot
  4. Use the plugin via the “Plugin –> TELEMAC Tools” – Menu or the Button (with the TELEMAC ICON) that should be available in the icon bars.
    Screenshot-QGIS 2.2.0-Valmiera
  5. Known limits: Currently tested with QGIS 2.2 to 2.8.1 (Linux & Windows)