code: def get_phonopy_structure(pmg_structure):
      
  
      symbols = [site.specie.symbol for site in pmg_structure]
  
      return PhonopyAtoms(symbols=symbols, cell=pmg_structure.lattice.matrix,
                          scaled_positions=pmg_structure.frac_coords)
docs: Convert a pymatgen Structure object to a PhonopyAtoms object.
  
      Args:
          pmg_structure (pymatgen Structure): A Pymatgen structure object.