Skip to content

Commit

Permalink
forward kwargs to ElectronicStructureRester
Browse files Browse the repository at this point in the history
  • Loading branch information
tschaume committed Dec 13, 2024
1 parent 5a5a190 commit 3af18ad
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions mp_api/client/routes/materials/electronic_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,14 @@ def get_bandstructure_from_material_id(
bandstructure (Union[BandStructure, BandStructureSymmLine]): BandStructure or BandStructureSymmLine object
"""
es_rester = ElectronicStructureRester(
endpoint=self.base_endpoint, api_key=self.api_key
api_key=self.api_key,
endpoint=self.base_endpoint,
include_user_agent=self.include_user_agent,
session=self.session,
monty_decode=self.monty_decode,
use_document_model=self.use_document_model,
headers=self.headers,
mute_progress_bars=self.mute_progress_bars,
)

if line_mode:
Expand Down Expand Up @@ -445,7 +452,14 @@ def get_dos_from_material_id(self, material_id: str):
dos (CompleteDos): CompleteDos object
"""
es_rester = ElectronicStructureRester(
endpoint=self.base_endpoint, api_key=self.api_key
api_key=self.api_key,
endpoint=self.base_endpoint,
include_user_agent=self.include_user_agent,
session=self.session,
monty_decode=self.monty_decode,
use_document_model=self.use_document_model,
headers=self.headers,
mute_progress_bars=self.mute_progress_bars,
)

dos_doc = es_rester.search(material_ids=material_id, fields=["dos"])
Expand Down

0 comments on commit 3af18ad

Please sign in to comment.