Welcome, Guest
Username: Password: Remember me

TOPIC: File format SERAFIN?

File format SERAFIN? 4 years 10 months ago #35161

  • nicogodet
  • nicogodet's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 157
  • Thank you received: 39
Hello,

Since V7P3, the default file format is "SERAFIN?" while possible values are SERAFIN, SERAFIND, MED.

It seems to cause several issues when I use PostTelemac (Qgis plugin for visualisation and computation) or when I try to import the result file in Qgis 3.10 using mdal.

If I force the result file format in cas file using FORMAT DU FICHIER DES RESULTATS ='SERAFIN' (RESULTS FILE FORMAT ='SERAFIN'), both PostTelemac and mdal work fine.

If we look closer and if we compare the structure of a serafin file (gdal.org/drivers/vector/selafin.html#full-structure), we can see that the result file using "SERAFIN?" key-word is not correct.
a string of 80 characters with the title of the study; the last 8 characters shall be “SERAPHIN” or “SERAFIN” or “SERAFIND”;
Using a binary reader, we can see that the last 8 caracters are blank.
When if force the file format to "SERAFIN", the last 8 caracters are indeed "SERAFIN". (see attached files)


Is that a mistake or feature ?

Regards,
Nicolas
Attachments:
The administrator has disabled public write access.

File format SERAFIN? 4 years 10 months ago #35164

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi
The definition in the gdal link is not the official one.
The official description is done in the Telemac-Mascaret documentation.
There was a first evolution when the double precision files was added to solve truncature problems for some high precision simulation(for water quality for example) and a second one when the MED format was also added.
This has been mostly treated in the visualisation and we don't see any problems with Qgis, whatever the version...

Regards
Christophe
The administrator has disabled public write access.
The following user(s) said Thank You: nicogodet

File format SERAFIN? 4 years 10 months ago #35165

  • nicogodet
  • nicogodet's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 157
  • Thank you received: 39
Hi,

After running few more test, it seems that Fudaa-Prepro could be the guilty.

My geo.slf is in double precision (I didn't notice before...) and it seems that telemac outputs are double precision too when i specify "SERAFIN?" or "SERAFIND".
Keyword "SERAFIN?" allows to output result at the same precision that input files, isn't it ?

When I use PostTelemac (Qgis 2.18.28) to compute the _Max.res of a double precision result, PostTelemac can't read the computed Max file.
Because of this, I used Fudaa to save the double precision result file as a simple precision one. It seems that Fudaa do not write correctly the fist 80 characters string (the last 8 characters are blank).
PostTelemac were able to correctly compute the max of the converted result file.

In Qgis 3.10.1, it seems that mdal can't read double precision files.

I can provide .res files if needed.


I was not able to find info about the new keyword "SERAFIN?" instead "SERAFIN".
Sorry for the inconvenience and thank you for your answer.

Regards,
The administrator has disabled public write access.
Moderators: pham

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.