Is there a program that converts Tcl into PY files?

Forum for asking and answering questions related to use of the OpenSeesPy module

Moderators: silvia, selimgunay, Moderators

Post Reply
YizheHe
Posts: 3
Joined: Thu Jun 11, 2020 10:43 pm

Is there a program that converts Tcl into PY files?

Post by YizheHe »

Is there a program like ETO that can convert Tcl on openSees to corresponding Py file?I didn't have to go back to modeling in Python, which would have been cumbersome.Thank you
YizheHe
Posts: 3
Joined: Thu Jun 11, 2020 10:43 pm

Re: Is there a program that converts Tcl into PY files?

Post by YizheHe »

Maybe someone wants to write this software?This makes openSeesPy a lot easier. There are many applications like SAP2000 and ETAPS that convert models to OpenSees models.We can save a lot of modeling time.
mhscott
Posts: 880
Joined: Tue Jul 06, 2004 3:38 pm
Location: Corvallis, Oregon USA
Contact:

Re: Is there a program that converts Tcl into PY files?

Post by mhscott »

This script works, but only if the Tcl file defines everything line by line, i.e., without loops, conditional statements, or variable substitutions.

https://github.com/OpenSees/OpenSees/bl ... nSeesPy.py
YizheHe
Posts: 3
Joined: Thu Jun 11, 2020 10:43 pm

Re: Is there a program that converts Tcl into PY files?

Post by YizheHe »

Thank you .Im so happy for it and I admire your work
ajmakdisi
Posts: 5
Joined: Wed Mar 19, 2014 10:02 am
Location: University of Washington

Re: Is there a program that converts Tcl into PY files?

Post by ajmakdisi »

I was actually wondering the exact opposite... is there any way to recover an equivalent .tcl file from an openseespy file?
mhscott
Posts: 880
Joined: Tue Jul 06, 2004 3:38 pm
Location: Corvallis, Oregon USA
Contact:

Re: Is there a program that converts Tcl into PY files?

Post by mhscott »

Why in the world would you want to do that? hahaha

It should be straightforward to reverse the Python script to go OpenSeesPy to OpenSeesTcl.
Post Reply