Entry

class emdb.models.entry.EMDBEntry(*, id: str, method: str | None = None, resolution: float | None = None, admin: Dict, citations: Dict, related_emdb_ids: List[Dict], related_pdb_ids: List[Dict], sample: Dict, structure_determination_list: List[Dict], modelling: List[Dict] | None = None, primary_map: PrimaryMapFile, metadata_files: List[EMDBMetadataXMLFile | EMDBMetadataCIFFile] = [], pdb_models: List[ModelCifFile] | None = [], half_maps: List[HalfMapFile] | None = [], additional_maps: List[AdditionalMapFile] | None = [], masks: List[MaskFile] | None = [], figure: FigureFile)[source]

Bases: BaseModel

classmethod from_api(data: dict, client: EMDB) EMDBEntry[source]

Create an EMDBEntry instance from API data.

Parameters:
  • data – Dictionary containing EMDB entry data.

  • client – An instance of EMDB client to interact with the API.

Returns:

An instance of EMDBEntry.

download_all_files(directory: str) None[source]

Download all files associated with this EMDB entry to the specified directory.

Parameters:

directory – The directory where files will be downloaded.

get_annotations() EMDBAnnotations | None[source]

Retrieve annotations for this EMDB entry.

Returns:

An instance of EMDBAnnotations if available, otherwise None.

get_validation() EMDBValidation | None[source]

Retrieve the validation data for this EMDB entry.

Returns:

An instance of EMDBValidation if available, otherwise None.

model_post_init(context: Any, /) None

This function is meant to behave like a BaseModel method to initialise private attributes.

It takes context as an argument since that’s what pydantic-core passes when calling it.

Parameters:
  • self – The BaseModel instance.

  • context – The context.

additional_maps: List[AdditionalMapFile] | None
admin: Dict
citations: Dict
property deposited_files: List[PrimaryMapFile | HalfMapFile | AdditionalMapFile | MaskFile | FigureFile | ModelCifFile]

Retrieve all files associated with this EMDB entry.

Returns:

A list of all file objects associated with the EMDB entry.

figure: FigureFile
half_maps: List[HalfMapFile] | None
id: str
masks: List[MaskFile] | None
metadata_files: List[EMDBMetadataXMLFile | EMDBMetadataCIFFile]
method: str | None
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

modelling: List[Dict] | None
pdb_models: List[ModelCifFile] | None
primary_map: PrimaryMapFile
related_emdb_ids: List[Dict]
related_pdb_ids: List[Dict]
resolution: float | None
sample: Dict
structure_determination_list: List[Dict]