You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
from sionna.rt import RadioMaterial
from sionna.rt import load_scene
#load_scene() # Load empty scene
custom_material = RadioMaterial("my_material",
relative_permittivity=2.0,
conductivity=5.0)
Error is Scene()._frequency is undefined because the init doesn't give it a default.
This does not error:
from sionna.rt import RadioMaterial
from sionna.rt import load_scene
load_scene() # Load empty scene
custom_material = RadioMaterial("my_material",
relative_permittivity=2.0,
conductivity=5.0)
It is clear from the API documentation that this is known. The api doc has the empty scene prior to defining the material.
The arrow of dependency is basically circular because of that reach in _frequency with no default on an undefined scene. Scene depends on materials and materials depend on Scene._frequency. Scene._frequency may change after materials are defined, so the necessity of this circular dependency is unclear.
From a high level there seems like there is a design where RadioMaterials can be defined independent of Scene and Scene uses them.
My interest is I just wanted some library of materials in a module. It is clear now though that to do so I will have to factory them after an initial scene load or do the load_scene() just to import, but I dont want to do that. Choosing factory method myself.
The text was updated successfully, but these errors were encountered:
This errors on a fresh python instance
Error is Scene()._frequency is undefined because the init doesn't give it a default.
This does not error:
It is clear from the API documentation that this is known. The api doc has the empty scene prior to defining the material.
The arrow of dependency is basically circular because of that reach in _frequency with no default on an undefined scene. Scene depends on materials and materials depend on Scene._frequency. Scene._frequency may change after materials are defined, so the necessity of this circular dependency is unclear.
From a high level there seems like there is a design where RadioMaterials can be defined independent of Scene and Scene uses them.
My interest is I just wanted some library of materials in a module. It is clear now though that to do so I will have to factory them after an initial scene load or do the load_scene() just to import, but I dont want to do that. Choosing factory method myself.
The text was updated successfully, but these errors were encountered: