Welcome, Guest
Username: Password: Remember me

TOPIC: Printout problem with additional variables when changing to Python3

Printout problem with additional variables when changing to Python3 4 years 1 month ago #36832

Hi everyone,

I am working in the coupling between Telemac(2D) and an ecological modeling software. I needed to compute several variables associated with hydrodynamics and water quality so I started using the private arrays that are available in Telemac; however, I never managed to get more than 4 variables working so I decided to add them from scratch, the process I followed for each variable was as follows:
  • Firstly, I declared the variable in "declarations_telemac2d.f"
  • Secondly, I allocated the array, added a pointer to graphic variables in the block VARSOR and initialized the variable in point_telemac2d.f
  • Finally, I modified nomvar_telemac2d.f and preres_telemac2d.f to give the variable a name, an alias and actually do the computation

I did some testing with both hydrodynamics and WAQTEL and it worked flawlessly until I recompiled using python3. The problem is that it is not recognizing any of the variables' aliases in the CAS file (not even the private arrays when I change their aliases in nomvar) I get the following error:
"The value for VARIABLES FOR GRAPHIC PRINTOUTS (variable_alias)is not among the choices:" (see screenshot)

I did managed to get it working by modifying the dictionary file, but the user manual strongly advise against modifying the telemac2d.dico. So I would like to ask what am I missing? what should I do to solve the issue without touching the dico file?

I would really appreciate if anyone can help me out.

Thanks a lot!
Attachments:
The administrator has disabled public write access.

Printout problem with additional variables when changing to Python3 4 years 1 month ago #36833

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi
Modifying dictionnary could be problematic but in your case, there is no other solution as the problem comes from the initial verification in python...
So you could try to change the dictionnary in a limited way, just in the list of available choices for the variables for graphic printout
Regards
Christophe
The administrator has disabled public write access.
The following user(s) said Thank You: nicoescobarc

Printout problem with additional variables when changing to Python3 4 years 1 month ago #36847

Thank you!

In that case I will proceed according to your recommendation.

Sincerely,

Nicolás
The administrator has disabled public write access.
Moderators: pham

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