Welcome, Guest
Username: Password: Remember me

TOPIC: installation problem

installation problem 11 years 8 months ago #7825

  • 716469
  • 716469's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 303
  • Thank you received: 6
Hi Martin,

I have just made some additions to the Environment variables. I had before
just c:\Python27;c:\Python27\Tools\Scripts and now I added more in front:

c:\opentelemac\v6p2\pytel;c:\Python27;c:\Python27\Tools\Scripts

so when I go to DOS Windows and type compileTLEMAC.py then I get more details of error: File"<stdin>" line 1, in <module>
NameError: name compileTELEMAC is not defined

I hope it helps. thanks.

Violeta
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7827

  • Termind
  • Termind's Avatar
Hi Violeta,

With that message, it looks as though you've typed python on its own and then typed compileTELEMAC.py as a line of Python code.

You do of course have to type python compileTELEMAC.py etc on a single line before pressing ENTER. And I do recommend that you have
c:\opentelemac\v6p2\pytel as your current directory.

If you still have a problem, try taking a screenshot of your Command Window (use Alt/Print Screen to copy to clipboard, paste into an application such as WordPad, save the file and attach).

Alternatively, reply with the exact command you used.

Martin
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7830

  • 716469
  • 716469's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 303
  • Thank you received: 6
thank you very much Martin for your explanations. I will do it tomorrow on my office computer and hopefully it will work, my home laptop is missing lots of things so I could not install Telemac here, but I will work on it tomorrow morning. Thanks again.

Kind Regards!

Violeta
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7841

  • 716469
  • 716469's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 303
  • Thank you received: 6
HI Martin,

some progress (I hope):). I changed the directory on DOS window and when I typed compileTELEMAC.py then Notepad document opened from pytel folder, the document is compileTELEMAC, the one you asked me to check yesterday. I did not get any errors in DOS window when typed compileTELEMAC.py but when I pressed enter then this document opened. I am not sure if it is right way. I will still experiment with changing directories in DOS window, eventually I will get it. Antoher thing: when I typed PATH in DOS window then I got the list of directories on PATH. I have noticed that c:\Python27;c:\Python27\Tools\Scripts appear twice, I think one is from User Variables and another one is from System Variables in Environment Variables screen. It is probably does not matter as far as they appear in DOS.
When I type python compileTELEMAC.py then DOS gives me error message : can't open file "compileTELE<AC.py": [Errno 2] No such file or directory . But when I just type compileTELEMAC.py without typing python in front of it then the CompileTELEMAC documnet opens in Notepad. I hope it is right.

thanks.

violeta
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7844

  • Termind
  • Termind's Avatar
There is something wrong with the file associations for .py files on your PC. So don't rely on clicking the .py file or running it directly.

To avoid the issue, always type python file.py.

And do ensure that c:\opentelemac\v6p2\pytel is the current directory when you type python compileTELEMAC.py etc.

Duplicate entries in the PATH values are not a problem.

Martin
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7848

  • 716469
  • 716469's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 303
  • Thank you received: 6
HI Martin,

I think I missed something in one of configuration files. Since I am using Window7 and FTN95 then I had to add it to one of the files in config, so I choose systel.cis-window. I made addition to the configuration line as winftn95, and created [winftn95], changed the root but I did not updated cmd_obj, cmd_lib and cmd_exe. And i think that is my problem. I am not sure what to codes should be for FTN95 and it is not easy to find them on fortran mnanual. Are you using FTN95 too?

thanks.

Violeta
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7849

  • gourish
  • gourish's Avatar
Hi Violeta,

Can you post the config file which you are using.

Best Regards,
Gourish
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7850

  • 716469
  • 716469's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 303
  • Thank you received: 6
HI Gourish,

thank you very much for trying to solve my problem and sorry to be a pain:). See attached copy i made of config file systel.cis-windows. I added winftn95 to the configuration line and at the end of the pages added [winftn95] and other data. I just copied it from another [wing95s], but i need to change it to according my fortran compiler, but I can not find the needed codes in fortran manual. Sorry about all mess. thanks a mil for a help.

Kind Regards!

Violeta
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7873

  • gourish
  • gourish's Avatar
Hi Violeta,

I was trying to compile Telemac using FTN95 compiler.
As per the one post forums.silverfrost.com/viewtopic.php?p=9...8b5db4b4edc33a6548e9 it indicates that there is no compiler option to compile a program which will read a binary file in big-endian format.

As you can notice in the compiler option given for compilers like gfortran and intel fortran in the respective Telemac config files, it indicates that the file operation of Telemac is in big-endian format. For example, gfotran has to pass "-fconvert=big-endian" option.

If you want to use FTN95 to compile Telemac, probably you will have to change the reading functions (for example READ to READF@) used in Telemac as indicated by the mentioned post, which further implies that the code will not be compatible with other compilers.

I would rather advice you if in case you are not able to get the option for FTN95 (big-endian and record-marker), then switch over to Intel-fortran compiler, or gfortran (free compiler).

Pertaining to gfortran compiler, you may download the mingw installer from sourceforge.net/projects/mingw/files/lat...ownload?source=files, which packages gfortran, and use the already existing config files for compilation. Second option is to download cygwin, which also bundles gfortran. With cygwin probably you may even be able to compiler Telemac in parallel.

With Best Regards,
Gourish
The administrator has disabled public write access.

installation problem 11 years 8 months ago #7826

  • Termind
  • Termind's Avatar
I'll answer your question, Violeta, but it's really moving on to general Windows knowledge. You probably need to consult an IT-literate colleague or friend for more info.

When you type Python (or any other program) on the command line, Windows will look in the current directory plus all directories listed in the PATH environment variable.

To see which directories they are, just type PATH on the command line. That will list the directories separated by semi-colons. Python would be loaded from the first directory in the list which contains Python.exe.

When you installed Python, the install program will have added your Python folder to the PATH.

But one last suggestion for your original problem.

At the command prompt use CD command to change the current directory to the pytel sub-folder of your TELEMAC source folder. If it's not on drive C, you'll also have to change the current drive.

Now, type your python compileTELEMAC.py etc command.

If you're still getting the SyntaxError message, I'm stuck.

Over to you, Gourish.

Martin
The administrator has disabled public write access.
Moderators: borisb

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