Welcome, Guest
Username: Password: Remember me

TOPIC: [Bugfix] converter.py generate_atm outputs wrong timedates

[Bugfix] converter.py generate_atm outputs wrong timedates 4 years 3 months ago #36439

  • tomsail
  • tomsail's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 43
  • Thank you received: 17
Hi all,

In TELEMAC pretel tools for python3 (trunk version V8P1R0), I found out that you need to specify the datetime and time tags BEFORE specifying the header of the generated Selafin.

(function input : geo file and a weather data file,
function output : weather information applied on the geo file)

Hences lines 183 to 193 in generate.py :
print('   +> writing header')
    # Write header
    atm.append_header_slf()

# <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
# ~~~~ writes ATM core ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    print('   +> setting variables')
    # TIME and DATE extraction
    atm.datetime = slf.datetime
    atm.tags['times'] = slf.tags['times']

become :
# <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
# ~~~~ writes ATM core ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    print('   +> setting times tags')
    # TIME and DATE extraction
    atm.datetime = slf.datetime
    atm.tags['times'] = slf.tags['times']
    print('   +> writing header')
    # Write header
    atm.append_header_slf()
    print('   +> setting variables')

I'd be keen to know if a Git(Lab) version of TELEMAC (or at least the python scripts) would be available soon?

Cheers
The administrator has disabled public write access.

[Bugfix] converter.py generate_atm outputs wrong timedates 4 years 3 months ago #36454

  • yugi
  • yugi's Avatar
  • OFFLINE
  • openTELEMAC Guru
  • Posts: 851
  • Thank you received: 244
Hi,

Thanks for the info.
I will push the corrections in the trunk.

So far only a subversion repository is available.
We are in the process of switching to a gitlab.
As for the date it is not defined yet.
There are 10 types of people in the world: those who understand binary, and those who don't.
The administrator has disabled public write access.
Moderators: borisb

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