Hello, Matthias,
At first, let me say Thank you for your decision to support python script!
Klayout was a wonderful tool.
With integrated python script engine, Klayout become much better for me.
I have a question about scripting or File Format.
What I want is to create an oasis file with file global property.
I setup Klayout includes python, then from the assistant window, I searched 'set_property'
and found 3 methods
Cell#set_property
Shape#set_property
Instance#set_proprety
But I cannot find a method to set a property which is associated globally with the entire OASIS file. Could you tell me the way to create such property?
Best Regards,
Masaki
Comments
Hi Masaki,
thank you for this feedback :-)
Right now, global properties are not supported, but that is something that may make sense to add.
I wonder what is the understanding of "global properties". Are you interested in the special properties too? Like top cell, bounding box or similar? Or are you interested in arbitrary properties outside the special property domain?
I employ global properties already to store PCell context information, so I have to be careful not to create a name clash.
Matthias
Dear Matthias,
Thank you for your positive answer to support such property.
My understanding of “global property” is not associate to geometries, instances nor cells.
According to semi P39 (31.8), PROPERTY placed just after START record are associated globally with the entire OASIS file.
Semi p44 is a subset of P39, but it requires such property as a mandatory records.
http://en.wikipedia.org/wiki/OASIS.MASK
Hi Masaki,
I see the point. But if you want to implement OASIS.MASK, I'd except you to face other, and more severe issues:
I think that even though OASIS.MASK is a subset of OASIS, a writer for OASIS.MASK is a different piece of software. Compatibility mainly refers to reading: if you're not interested in the additional information from an OASIS.MASK file, you can load OASIS.MASK with a normal OASIS reader.
Regards,
Matthias
Hi, Matthias,
Thank you for your reply, my goal is not make exact OASIS.MASK but make a oasis include information not associated to any cells. So, I can avoid 2,3 and 4th issues you listed,if there is file global properties
Your answer clarify my another issue, thank you very much! So, I have a question about the first issue of your list. Although I only check a very small number of cells made by python script, I think the order seems to be controllable by order of calling insert method of sub cells. My understanding is wrong? The order of cells are not guaranteed when increase the number of cells just like a hash table?
Even in case of the order of the cell is not controllable by script, I do not make a request about the cell order control because I understand assuming controlled cell order is illegal usage within P39.
Best Regards,
Masaki
Hi Masaki,
To be frank, I can't give a simple answer to the cell order question, but I think in a simple application like yours the order of the cells written will be the order the cells are created.
I'll note your request about the global properties. But that's not a simple change so that will be something for a major release.
Matthias
Hi, Matthias,
Thank you for your commnet,
I asume order of cells by my own risk (or change my plan)
Also, thank you for appending my request to your stack!
Best Regards,
Masaki