"""Define Makers for Magnetic ordering flow in FHI-aims."""from__future__importannotationsfromdataclassesimportdataclass,fieldfromtypingimportTYPE_CHECKINGfrompymatgen.io.aims.sets.magnetismimport(MagneticRelaxSetGenerator,MagneticStaticSetGenerator,)ifTYPE_CHECKING:frompymatgen.io.aims.sets.baseimportAimsInputGeneratorfromatomate2.aims.jobs.coreimportRelaxMaker,StaticMaker
[docs]@dataclassclassMagneticStaticMaker(StaticMaker):"""Maker to create FHI-aims SCF jobs. Parameters ---------- calc_type: str The type key for the calculation name: str The job name input_set_generator: .AimsInputGenerator The InputGenerator for the calculation """calc_type:str="magnetic_scf"name:str="Magnetic SCF Calculation"input_set_generator:AimsInputGenerator=field(default_factory=MagneticStaticSetGenerator)
[docs]@dataclassclassMagneticRelaxMaker(RelaxMaker):"""Maker to create relaxation calculations. Parameters ---------- calc_type: str The type key for the calculation name: str The job name input_set_generator: .AimsInputGenerator The InputGenerator for the calculation """calc_type:str="relax"name:str="Magnetic Relaxation calculation"input_set_generator:AimsInputGenerator=field(default_factory=MagneticRelaxSetGenerator)
[docs]@classmethoddeffixed_cell_relaxation(cls,*args,**kwargs)->RelaxMaker:"""Create a fixed cell relaxation maker."""returncls(input_set_generator=MagneticRelaxSetGenerator(*args,relax_cell=False,**kwargs),name=cls.name+" (fixed cell)",)
[docs]@classmethoddeffull_relaxation(cls,*args,**kwargs)->RelaxMaker:"""Create a full relaxation maker."""returncls(input_set_generator=MagneticRelaxSetGenerator(*args,relax_cell=True,**kwargs))