oepolars-mae 0.1.0
“Schrodinger file format support for OEPolars”
Release published within seven daysimports os
SHA-25650cc220cb16c54164bb1ffd7d12df10b1019c5fb5b3b2369ed414b3f55e1ffdb
MaleculeH(Db₂)Md₂(InPa)
Evidence
0Metadata-Version: 2.4
Name: oepolars-mae
Version: 0.1.0
Summary: Schrodinger file format support for OEPolars
Author-email: Scott Arne Johnson <[email protected]>
License-Expression: MIT
Keywords: science
Classifier: Development Status :: 5 - Production/Stable
Classifier: Programming Language :: Python :: 3 :: Only
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: oepolars>=0.2.0
Requires-Dist: oemaestro>=0.4.1
Provides-Extra: dev
Requires-Dist: invoke; extra == "dev"
Requires-Dist: build; extra == "dev"
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: pytest-cov; extra == "dev"
24:22… g.Formatter.format(self, record)
25
26
27ch = logging.StreamHandler()
28ch.setLevel(logging.DEBUG)
29ch.setFormatter(LevelSpecificFormatter())
30log.addHandler(ch)
31log.setLevel(logging.INFO)
32
33# ---- Public API ----
34
35# ---- Auto-registration ----
36import polars as pl # noqa: E402
37
38from ._compat import ( # noqa: E402
39 PERCEPTION_ALL,
40 PERCEPTION_BOND_ORDERS,
41 PERCEPTION_CONNECTIVITY,
42 PERCEPTION_DEFAULT,
43 PERCEPTION_FORMAL_CHARGES,
44 PERCEPTION_IMPLICIT_HYDROGENS,
45 PERCEPTION_NONE,
46 PERCEPTION_RINGS,
47 TAG_ALL,
48 TAG_NAME,
49 TAG_NONE,
50 TAG_OWNER,
51 TAG_TYPE,
52 OEMaestroReaderConfig,
53)
54from .reader import read_mae # noqa: E402
55
56pl.read_mae = read_mae
57
58try:
59 import oepolars # noqa: E402
60 oepolars.read_mae = read_mae
61except ImportError:
62 pass
63
⋯8 lines
1"""Maestro file reader for oepolars."""
2from __future__ import annotations
3
4import logging
5import os
6from collections.abc import Iterable
7from typing import Literal
8
9import polars as pl
10from oepolars.types import MoleculeType
11from openeye import oechem
12
13from ._compat import (
14 TAG_NAME,
15 TAG_NONE,
16 TAG_OWNER,
17 TAG_TYPE,
18 MaestroMol,
19 MaestroReader,
20 MolConverter,
21 OEMaestroReaderConfig,
22)
23
⋯4 lines
58:15… Maestro's backslash-escaped underscores in free-text fields
59 name = name.replace("\\_", "_")
60
61 parts: list[str] = []
62 if tag_flags & TAG_TYPE:
63 parts.append(type_char)
64 if tag_flags & TAG_OWNER …
291:54… lid option.
292 """
293 # ---- Validate conformer_test ----
294 if conformer_test not in _CONF_TESTS:
295 raise ValueError(
296 f"Invalid conformer_test '{conformer_test}'. " f"Valid options: {list(_CONF_TESTS.keys()) …
No evidence locations were recorded for this file. Raw result