I am new to the forum. Writing a tkinter gui program based on Denis Berthier four grid transforms. I am contemplating calculating some python constants for one of my modules. The reason is that it is actually easier for me to calculate it! I have NOT found any references to anyone doing this?! I am going to calculate it in the constructor of this "Grid" class (there are 4 grids) Currently, I define it at the top of the module outside the class as LITTE_NUMBER_TAGS = None with a comment:
# calculated by the constructor
Obviously, I could build it somewhere else and use pretty print to load it into my Grid module. I have done it that way in the past. Problems from doing it that way in the
past is I lost the method I used to calculate it and I really don't "like" having this big constant (a list) taking up so much room in my module and for "some reason" I like embedding in my code the means for calculating it in the first place.
Is anyone aware of others doing this? Does it make sense, etc.?
Blessings,
# calculated by the constructor
Obviously, I could build it somewhere else and use pretty print to load it into my Grid module. I have done it that way in the past. Problems from doing it that way in the
past is I lost the method I used to calculate it and I really don't "like" having this big constant (a list) taking up so much room in my module and for "some reason" I like embedding in my code the means for calculating it in the first place.
Is anyone aware of others doing this? Does it make sense, etc.?
Blessings,