Skip to content

Commit

Permalink
update class config for pydanticv2
Browse files Browse the repository at this point in the history
MatthewMckee4 committed Jan 19, 2025
1 parent c57eae0 commit df9cc0a
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions gdsfactory/generic_tech/simulation_settings.py
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
from functools import partial

import numpy as np
from pydantic import BaseModel
from pydantic import BaseModel, ConfigDict
from scipy import interpolate

material_name_to_lumerical_default = {
@@ -52,10 +52,9 @@ class SimulationSettingsLumericalFdtd(BaseModel):
distance_monitors_to_pml: float = 0.5
material_name_to_lumerical: dict[str, str] = material_name_to_lumerical_default

class Config:
"""pydantic basemodel config."""

arbitrary_types_allowed = True
model_config = ConfigDict(
arbitrary_types_allowed=True,
)


SIMULATION_SETTINGS_LUMERICAL_FDTD = SimulationSettingsLumericalFdtd()

0 comments on commit df9cc0a

Please sign in to comment.