Skip to content

Commit

Permalink
enable the wp as the numbers in from_spg_wps_rep
Browse files Browse the repository at this point in the history
  • Loading branch information
qzhu2017 committed Dec 12, 2024
1 parent c833cd1 commit 32df96f
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions pyxtal/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3484,12 +3484,15 @@ def from_spg_wps_rep(self, spg, wps, x, elements=None):
group = Group(spg)
sites = []
for i, _wp in enumerate(wps):
letter = _wp[-1]
for wp in group:
if wp.letter == letter:
sites.append((elements[i], wp))
break
self.from_1d_rep(x, sites)
if type(_wp) is int:
sites.append((elements[i], group[_wp]))
else:
letter = _wp[-1]
for wp in group:
if wp.letter == letter:
sites.append((elements[i], wp))
break
self.from_1d_rep(x, sites, normalize)

def from_1d_rep(self, x, sites, dim=3):
"""
Expand Down

0 comments on commit 32df96f

Please sign in to comment.