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
When trying to retrieve parameters for materials that are not built-in properties, like the doping concentration Na or Nd, the material retrieval fails. This is done in this line:
Ideally, the solution should be implemented in solcore adding a default call to the parent's __getattr__ after the custom one has gone through several options and before calling ParameterSystem. The simplest, sunglass only solution would be to check __getattribute__ IF AND ONLY IF __getattr__ fails as the first one checks the whole spectrum of attributes of the material.
The text was updated successfully, but these errors were encountered:
Problem
When trying to retrieve parameters for materials that are not built-in properties, like the doping concentration Na or Nd, the material retrieval fails. This is done in this line:
sunglass/sunglass/solar_cells.py
Line 872 in 7c57c8f
The reason is that actual instance attributes are not really search by the overwritten
__getattr__
method insolcore
:https://github.com/qpv-research-group/solcore5/blob/a5e0dae8f445cf43922c1e65bbfd6bbf644ac69b/solcore/material_system/material_system.py#L301
Possible solution
Ideally, the solution should be implemented in
solcore
adding a default call to the parent's__getattr__
after the custom one has gone through several options and before callingParameterSystem
. The simplest,sunglass
only solution would be to check__getattribute__
IF AND ONLY IF__getattr__
fails as the first one checks the whole spectrum of attributes of the material.The text was updated successfully, but these errors were encountered: