30 lines
933 B
Python
30 lines
933 B
Python
from pydantic import BaseModel, ConfigDict, Field
|
|
from typing_extensions import Literal
|
|
|
|
|
|
class GaussianConfig(BaseModel):
|
|
"""
|
|
Data Transfer Object for the Gaussian configuration.
|
|
"""
|
|
|
|
model_config = ConfigDict(
|
|
frozen=True,
|
|
)
|
|
|
|
qmprog: Literal["g03", "g09", "g16"] = Field(
|
|
"g16", description="QM program to use for the calculations"
|
|
)
|
|
level: str = Field(..., description="Level of theory for the QM calculations")
|
|
|
|
chgmult: list[int] = Field(
|
|
default_factory=lambda: [0, 1],
|
|
description="List of charge and multiplicity for the QM calculations",
|
|
)
|
|
pop: str = Field(
|
|
"chelpg", description="Population analysis method for the QM calculations"
|
|
)
|
|
chg_tol: float = Field(0.01, description="Charge tolerance for the QM calculations")
|
|
keywords: str | None = Field(
|
|
None, description="Additional keywords for the QM calculations"
|
|
)
|