Skip to content

Commit

Permalink
Added further changes analogue to melting temperature.
Browse files Browse the repository at this point in the history
  • Loading branch information
shiemer committed Aug 16, 2024
1 parent 86b72be commit 653aa6d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion calphy/input.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,8 @@ class Calculation(BaseModel, title='Main input class'):
berendsen: Optional[Berendsen] = Berendsen()
queue: Optional[Queue] = Queue()
tolerance: Optional[Tolerance] = Tolerance()
melting_temperature: Optional[MeltingTemperature] = MeltingTemperature()
melting_temperature: Optional[MeltingTemperature] = MeltingTemperature()
transformation_temperature: Optional[TransformationTemperature] = TransformationTemperature()
element: Annotated[List[str], BeforeValidator(to_list),
Field(default=[])]
n_elements: Annotated[int, Field(default=0)]
Expand Down
6 changes: 3 additions & 3 deletions calphy/routines.py
Original file line number Diff line number Diff line change
Expand Up @@ -341,8 +341,8 @@ def __init__(self, calculation=None, simfolder=None, log_to_screen=False):
self.calc = calculation
self.simfolder = simfolder
self.log_to_screen = log_to_screen
self.dtemp = self.calc.melting_temperature.step
self.maxattempts = self.calc.melting_temperature.attempts
self.dtemp = self.calc.transformation_temperature.step
self.maxattempts = self.calc.transformation_temperature.attempts
self.attempts = 0
self.calculations = []

Expand Down Expand Up @@ -386,7 +386,7 @@ def prepare_calcs(self):

calc["mode"] = "ts"
calc["temperature"] = [int(self.tmin), int(self.tmax)]
calc["reference_phase"] = 'liquid'
calc["reference_phase"] = 'solid'
calculations["calculations"].append(calc)

outfile = f'{self.calc.create_identifier()}.{self.attempts}.yaml'
Expand Down

0 comments on commit 653aa6d

Please sign in to comment.