-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
to_ase
error when kind name includes string tag.
#26
Comments
Hi @xing, thanks a lot for testing the StructureData. In this case, the issue is in the ASE object: the tags are strings ('_up','_down'), whereas ASE accepts only integers. structure_dict = {
'cell':[[2.75,2.75,0],[0,2.75,2.75],[2.75,0,2.75]],
'pbc': [True,True,True],
'sites':[
{
'symbol':'Si',
'position':[3/4, 3/4, 3/4],
'charge': +1,
'kind_name': 'Si0',
},
{
'symbol':'Si',
'position':[1/2, 1/2, 1/2],
'kind_name': 'Si1',
},
],
}
mutable_structure = StructureDataMutable(**structure_dict)
structure = StructureData(**structure_dict)
structure.to_ase().get_tags() tags being [0,1]. Do you think that we should provide a check for the kind_names? i.e. to provide only the element+integers, or we should automatically change Si_up to Si0? I think we should not allow element+strings, as also in ASE it is not allowed to provide tags as strings. |
The old However, this makes the user somehow confused, because the kind name is changed, which may affect other input parameters. |
Error message
The text was updated successfully, but these errors were encountered: