def get_astral(astral_id, structure=True, pdir="/tmp/structures"): """Returns a PDB structure downloaded from the astral ftp server""" from hpf.pdb.astral import AstralList al = AstralList(pdir=pdir, sdir=pdir, obsolete_pdb=True) if structure: return al.retrieve_astral(astral_id) else: return al.retrieve_astral_file(astral_id)