cognite-neat 0.119.9__py3-none-any.whl → 0.121.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of cognite-neat might be problematic. Click here for more details.
- cognite/neat/__init__.py +3 -2
- cognite/neat/_version.py +1 -1
- cognite/neat/{_client → core/_client}/_api/data_modeling_loaders.py +5 -5
- cognite/neat/{_client → core/_client}/_api/neat_instances.py +1 -1
- cognite/neat/{_client → core/_client}/_api/schema.py +9 -5
- cognite/neat/{_client → core/_client}/_api_client.py +1 -1
- cognite/neat/{_client → core/_client}/data_classes/schema.py +4 -4
- cognite/neat/{_client → core/_client}/testing.py +1 -1
- cognite/neat/{_constants.py → core/_constants.py} +27 -8
- cognite/neat/{_graph → core/_graph}/_tracking/base.py +1 -1
- cognite/neat/{_graph → core/_graph}/_tracking/log.py +1 -1
- cognite/neat/{_graph → core/_graph}/extractors/__init__.py +1 -1
- cognite/neat/{_graph → core/_graph}/extractors/_base.py +6 -6
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_base.py +23 -7
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_classic.py +16 -12
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_files.py +10 -3
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_relationships.py +5 -3
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_sequences.py +7 -2
- cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_timeseries.py +10 -3
- cognite/neat/{_graph → core/_graph}/extractors/_dict.py +2 -2
- cognite/neat/{_graph → core/_graph}/extractors/_dms.py +6 -6
- cognite/neat/{_graph → core/_graph}/extractors/_dms_graph.py +15 -11
- cognite/neat/{_graph → core/_graph}/extractors/_mock_graph_generator.py +10 -10
- cognite/neat/{_graph → core/_graph}/extractors/_raw.py +3 -3
- cognite/neat/{_graph → core/_graph}/extractors/_rdf_file.py +10 -7
- cognite/neat/{_graph → core/_graph}/loaders/_base.py +5 -5
- cognite/neat/{_graph → core/_graph}/loaders/_rdf2dms.py +31 -18
- cognite/neat/{_graph → core/_graph}/queries/_select.py +3 -3
- cognite/neat/{_graph → core/_graph}/queries/_update.py +1 -1
- cognite/neat/{_graph → core/_graph}/transformers/_base.py +8 -4
- cognite/neat/{_graph → core/_graph}/transformers/_classic_cdf.py +6 -6
- cognite/neat/{_graph → core/_graph}/transformers/_prune_graph.py +4 -4
- cognite/neat/{_graph → core/_graph}/transformers/_rdfpath.py +1 -1
- cognite/neat/{_graph → core/_graph}/transformers/_value_type.py +8 -4
- cognite/neat/{_issues → core/_issues}/_base.py +12 -5
- cognite/neat/{_issues → core/_issues}/_contextmanagers.py +1 -1
- cognite/neat/{_issues → core/_issues}/_factory.py +2 -2
- cognite/neat/{_issues → core/_issues}/errors/__init__.py +1 -1
- cognite/neat/{_issues → core/_issues}/errors/_external.py +1 -1
- cognite/neat/{_issues → core/_issues}/errors/_general.py +1 -1
- cognite/neat/{_issues → core/_issues}/errors/_properties.py +1 -1
- cognite/neat/{_issues → core/_issues}/errors/_resources.py +7 -2
- cognite/neat/{_issues → core/_issues}/errors/_wrapper.py +2 -2
- cognite/neat/{_issues → core/_issues}/warnings/__init__.py +1 -1
- cognite/neat/{_issues → core/_issues}/warnings/_external.py +1 -1
- cognite/neat/{_issues → core/_issues}/warnings/_general.py +1 -1
- cognite/neat/{_issues → core/_issues}/warnings/_models.py +2 -2
- cognite/neat/{_issues → core/_issues}/warnings/_properties.py +2 -2
- cognite/neat/{_issues → core/_issues}/warnings/_resources.py +6 -1
- cognite/neat/{_issues → core/_issues}/warnings/user_modeling.py +1 -1
- cognite/neat/{_rules → core/_rules}/_shared.py +6 -4
- cognite/neat/{_rules → core/_rules}/analysis/_base.py +15 -8
- cognite/neat/{_rules → core/_rules}/exporters/_base.py +7 -7
- cognite/neat/{_rules → core/_rules}/exporters/_rules2dms.py +15 -9
- cognite/neat/{_rules → core/_rules}/exporters/_rules2excel.py +219 -163
- cognite/neat/{_rules → core/_rules}/exporters/_rules2instance_template.py +4 -4
- cognite/neat/{_rules → core/_rules}/exporters/_rules2ontology.py +10 -10
- cognite/neat/{_rules → core/_rules}/exporters/_rules2yaml.py +1 -1
- cognite/neat/{_rules → core/_rules}/exporters/_validation.py +2 -2
- cognite/neat/{_rules → core/_rules}/importers/_base.py +5 -5
- cognite/neat/{_rules → core/_rules}/importers/_dms2rules.py +20 -12
- cognite/neat/{_rules → core/_rules}/importers/_dtdl2rules/dtdl_converter.py +15 -7
- cognite/neat/{_rules → core/_rules}/importers/_dtdl2rules/dtdl_importer.py +13 -9
- cognite/neat/{_rules → core/_rules}/importers/_dtdl2rules/spec.py +1 -1
- cognite/neat/{_rules → core/_rules}/importers/_rdf/_base.py +12 -12
- cognite/neat/{_rules → core/_rules}/importers/_rdf/_imf2rules.py +5 -2
- cognite/neat/{_rules → core/_rules}/importers/_rdf/_inference2rules.py +14 -14
- cognite/neat/{_rules → core/_rules}/importers/_rdf/_owl2rules.py +5 -2
- cognite/neat/{_rules → core/_rules}/importers/_rdf/_shared.py +4 -4
- cognite/neat/{_rules → core/_rules}/importers/_spreadsheet2rules.py +7 -7
- cognite/neat/{_rules → core/_rules}/importers/_yaml2rules.py +5 -5
- cognite/neat/{_rules → core/_rules}/models/__init__.py +5 -3
- cognite/neat/{_rules → core/_rules}/models/_base_rules.py +9 -6
- cognite/neat/{_rules → core/_rules}/models/_types.py +5 -5
- cognite/neat/{_rules → core/_rules}/models/data_types.py +9 -3
- cognite/neat/{_rules → core/_rules}/models/dms/__init__.py +1 -1
- cognite/neat/{_rules → core/_rules}/models/dms/_exporter.py +15 -8
- cognite/neat/{_rules → core/_rules}/models/dms/_rules.py +9 -9
- cognite/neat/{_rules → core/_rules}/models/dms/_rules_input.py +10 -7
- cognite/neat/{_rules → core/_rules}/models/dms/_validation.py +14 -14
- cognite/neat/{_rules → core/_rules}/models/entities/_loaders.py +2 -2
- cognite/neat/{_rules → core/_rules}/models/entities/_multi_value.py +2 -2
- cognite/neat/{_rules → core/_rules}/models/entities/_single_value.py +3 -3
- cognite/neat/{_rules → core/_rules}/models/information/_rules.py +11 -9
- cognite/neat/{_rules → core/_rules}/models/information/_rules_input.py +5 -5
- cognite/neat/{_rules → core/_rules}/models/information/_validation.py +10 -10
- cognite/neat/{_rules → core/_rules}/models/mapping/_classic2core.py +5 -5
- cognite/neat/{_rules → core/_rules}/transformers/_base.py +4 -4
- cognite/neat/{_rules → core/_rules}/transformers/_converters.py +52 -26
- cognite/neat/{_rules → core/_rules}/transformers/_mapping.py +15 -7
- cognite/neat/{_rules → core/_rules}/transformers/_verification.py +7 -7
- cognite/neat/{_store → core/_store}/_graph_store.py +13 -10
- cognite/neat/{_store → core/_store}/_provenance.py +3 -3
- cognite/neat/{_store → core/_store}/_rules_store.py +19 -12
- cognite/neat/{_store → core/_store}/exceptions.py +4 -4
- cognite/neat/core/_utils/__init__.py +0 -0
- cognite/neat/{_utils → core/_utils}/auth.py +1 -1
- cognite/neat/{_utils → core/_utils}/auxiliary.py +1 -1
- cognite/neat/{_utils → core/_utils}/collection_.py +2 -2
- cognite/neat/{_utils → core/_utils}/graph_transformations_report.py +1 -1
- cognite/neat/{_utils → core/_utils}/rdf_.py +1 -1
- cognite/neat/{_utils → core/_utils}/reader/_base.py +1 -1
- cognite/neat/{_utils → core/_utils}/spreadsheet.py +11 -4
- cognite/neat/{_utils → core/_utils}/text.py +1 -1
- cognite/neat/{_utils → core/_utils}/upload.py +3 -3
- cognite/neat/{_session → session}/_base.py +10 -10
- cognite/neat/{_session → session}/_collector.py +1 -1
- cognite/neat/{_session → session}/_drop.py +3 -3
- cognite/neat/{_session → session}/_explore.py +2 -2
- cognite/neat/{_session → session}/_fix.py +2 -2
- cognite/neat/{_session → session}/_inspect.py +7 -3
- cognite/neat/{_session → session}/_mapping.py +3 -3
- cognite/neat/{_session → session}/_prepare.py +8 -8
- cognite/neat/{_session → session}/_read.py +130 -16
- cognite/neat/{_session → session}/_set.py +8 -8
- cognite/neat/{_session → session}/_show.py +5 -5
- cognite/neat/{_session → session}/_state.py +8 -8
- cognite/neat/{_session → session}/_subset.py +7 -4
- cognite/neat/{_session → session}/_template.py +22 -14
- cognite/neat/{_session → session}/_to.py +12 -12
- cognite/neat/{_session → session}/_wizard.py +1 -1
- cognite/neat/{_session → session}/engine/_load.py +1 -1
- cognite/neat/{_session → session}/exceptions.py +4 -4
- {cognite_neat-0.119.9.dist-info → cognite_neat-0.121.0.dist-info}/METADATA +1 -1
- cognite_neat-0.121.0.dist-info/RECORD +187 -0
- cognite_neat-0.119.9.dist-info/RECORD +0 -186
- /cognite/neat/{_client/_api → core}/__init__.py +0 -0
- /cognite/neat/{_client → core/_client}/__init__.py +0 -0
- /cognite/neat/{_client/data_classes → core/_client/_api}/__init__.py +0 -0
- /cognite/neat/{_graph → core/_client/data_classes}/__init__.py +0 -0
- /cognite/neat/{_client → core/_client}/data_classes/data_modeling.py +0 -0
- /cognite/neat/{_client → core/_client}/data_classes/neat_sequence.py +0 -0
- /cognite/neat/{_config.py → core/_config.py} +0 -0
- /cognite/neat/{_graph/extractors/_classic_cdf → core/_graph}/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/_shared.py +0 -0
- /cognite/neat/{_graph → core/_graph}/_tracking/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/examples/Knowledge-Graph-Nordic44-dirty.xml +0 -0
- /cognite/neat/{_graph → core/_graph}/examples/Knowledge-Graph-Nordic44.xml +0 -0
- /cognite/neat/{_graph → core/_graph}/examples/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/examples/skos-capturing-sheet-wind-topics.xlsx +0 -0
- /cognite/neat/{_rules → core/_graph/extractors/_classic_cdf}/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_assets.py +0 -0
- /cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_data_sets.py +0 -0
- /cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_events.py +0 -0
- /cognite/neat/{_graph → core/_graph}/extractors/_classic_cdf/_labels.py +0 -0
- /cognite/neat/{_graph → core/_graph}/loaders/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/queries/__init__.py +0 -0
- /cognite/neat/{_graph → core/_graph}/queries/_base.py +0 -0
- /cognite/neat/{_graph → core/_graph}/queries/_queries.py +0 -0
- /cognite/neat/{_graph → core/_graph}/transformers/__init__.py +0 -0
- /cognite/neat/{_issues → core/_issues}/__init__.py +0 -0
- /cognite/neat/{_issues → core/_issues}/formatters.py +0 -0
- /cognite/neat/{_utils → core/_rules}/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/_constants.py +0 -0
- /cognite/neat/{_rules → core/_rules}/analysis/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/catalog/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/catalog/classic_model.xlsx +0 -0
- /cognite/neat/{_rules → core/_rules}/catalog/hello_world_pump.xlsx +0 -0
- /cognite/neat/{_rules → core/_rules}/catalog/info-rules-imf.xlsx +0 -0
- /cognite/neat/{_rules → core/_rules}/exporters/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/importers/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/importers/_dtdl2rules/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/importers/_dtdl2rules/_unit_lookup.py +0 -0
- /cognite/neat/{_rules → core/_rules}/importers/_rdf/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/_base_input.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/entities/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/entities/_constants.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/entities/_types.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/entities/_wrapped.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/information/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/mapping/__init__.py +0 -0
- /cognite/neat/{_rules → core/_rules}/models/mapping/_classic2core.yaml +0 -0
- /cognite/neat/{_rules → core/_rules}/transformers/__init__.py +0 -0
- /cognite/neat/{_shared.py → core/_shared.py} +0 -0
- /cognite/neat/{_store → core/_store}/__init__.py +0 -0
- /cognite/neat/{_utils → core/_utils}/io_.py +0 -0
- /cognite/neat/{_utils → core/_utils}/reader/__init__.py +0 -0
- /cognite/neat/{_utils → core/_utils}/time_.py +0 -0
- /cognite/neat/{_utils → core/_utils}/xml_.py +0 -0
- /cognite/neat/{_session → session}/__init__.py +0 -0
- /cognite/neat/{_alpha.py → session/_experimental.py} +0 -0
- /cognite/neat/{_state → session/_state}/README.md +0 -0
- /cognite/neat/{_session → session}/engine/__init__.py +0 -0
- /cognite/neat/{_session → session}/engine/_import.py +0 -0
- /cognite/neat/{_session → session}/engine/_interface.py +0 -0
- {cognite_neat-0.119.9.dist-info → cognite_neat-0.121.0.dist-info}/WHEEL +0 -0
- {cognite_neat-0.119.9.dist-info → cognite_neat-0.121.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -6,16 +6,16 @@ import pandas as pd
|
|
|
6
6
|
from cognite.client import data_modeling as dm
|
|
7
7
|
from rdflib import Namespace, URIRef
|
|
8
8
|
|
|
9
|
-
from cognite.neat._constants import DEFAULT_NAMESPACE
|
|
10
|
-
from cognite.neat._rules.models._base_input import InputComponent, InputRules
|
|
11
|
-
from cognite.neat._rules.models.data_types import DataType
|
|
12
|
-
from cognite.neat._rules.models.entities import (
|
|
9
|
+
from cognite.neat.core._constants import DEFAULT_NAMESPACE
|
|
10
|
+
from cognite.neat.core._rules.models._base_input import InputComponent, InputRules
|
|
11
|
+
from cognite.neat.core._rules.models.data_types import DataType
|
|
12
|
+
from cognite.neat.core._rules.models.entities import (
|
|
13
13
|
ClassEntity,
|
|
14
14
|
MultiValueTypeInfo,
|
|
15
15
|
UnknownEntity,
|
|
16
16
|
load_value_type,
|
|
17
17
|
)
|
|
18
|
-
from cognite.neat._utils.rdf_ import uri_display_name
|
|
18
|
+
from cognite.neat.core._utils.rdf_ import uri_display_name
|
|
19
19
|
|
|
20
20
|
from ._rules import (
|
|
21
21
|
InformationClass,
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import itertools
|
|
2
2
|
from collections import Counter, defaultdict
|
|
3
3
|
|
|
4
|
-
from cognite.neat._issues import IssueList
|
|
5
|
-
from cognite.neat._issues.errors import NeatValueError
|
|
6
|
-
from cognite.neat._issues.errors._resources import (
|
|
4
|
+
from cognite.neat.core._issues import IssueList
|
|
5
|
+
from cognite.neat.core._issues.errors import NeatValueError
|
|
6
|
+
from cognite.neat.core._issues.errors._resources import (
|
|
7
7
|
ResourceDuplicatedError,
|
|
8
8
|
ResourceNotDefinedError,
|
|
9
9
|
)
|
|
10
|
-
from cognite.neat._issues.warnings._models import UndefinedClassWarning
|
|
11
|
-
from cognite.neat._issues.warnings._resources import (
|
|
10
|
+
from cognite.neat.core._issues.warnings._models import UndefinedClassWarning
|
|
11
|
+
from cognite.neat.core._issues.warnings._resources import (
|
|
12
12
|
ResourceNotDefinedWarning,
|
|
13
13
|
ResourceRegexViolationWarning,
|
|
14
14
|
)
|
|
15
|
-
from cognite.neat._rules._constants import PATTERNS, EntityTypes
|
|
16
|
-
from cognite.neat._rules.models.entities import ClassEntity, UnknownEntity
|
|
17
|
-
from cognite.neat._rules.models.entities._multi_value import MultiValueTypeInfo
|
|
18
|
-
from cognite.neat._utils.spreadsheet import SpreadsheetRead
|
|
19
|
-
from cognite.neat._utils.text import humanize_collection
|
|
15
|
+
from cognite.neat.core._rules._constants import PATTERNS, EntityTypes
|
|
16
|
+
from cognite.neat.core._rules.models.entities import ClassEntity, UnknownEntity
|
|
17
|
+
from cognite.neat.core._rules.models.entities._multi_value import MultiValueTypeInfo
|
|
18
|
+
from cognite.neat.core._utils.spreadsheet import SpreadsheetRead
|
|
19
|
+
from cognite.neat.core._utils.text import humanize_collection
|
|
20
20
|
|
|
21
21
|
from ._rules import InformationRules
|
|
22
22
|
|
|
@@ -3,9 +3,9 @@ from pathlib import Path
|
|
|
3
3
|
|
|
4
4
|
import yaml
|
|
5
5
|
|
|
6
|
-
from cognite.neat._issues.errors import NeatValueError
|
|
7
|
-
from cognite.neat._rules._shared import ReadRules
|
|
8
|
-
from cognite.neat._rules.models.dms import DMSInputRules, DMSRules
|
|
6
|
+
from cognite.neat.core._issues.errors import NeatValueError
|
|
7
|
+
from cognite.neat.core._rules._shared import ReadRules
|
|
8
|
+
from cognite.neat.core._rules.models.dms import DMSInputRules, DMSRules
|
|
9
9
|
|
|
10
10
|
_CLASSIC_TO_CORE_MAPPING = Path(__file__).resolve().parent / "_classic2core.yaml"
|
|
11
11
|
|
|
@@ -16,8 +16,8 @@ def _read_source_file() -> str:
|
|
|
16
16
|
|
|
17
17
|
|
|
18
18
|
def load_classic_to_core_mapping(org_name: str | None, source_space: str, source_version: str) -> DMSRules:
|
|
19
|
-
from cognite.neat._rules.importers import YAMLImporter
|
|
20
|
-
from cognite.neat._rules.transformers import VerifyDMSRules
|
|
19
|
+
from cognite.neat.core._rules.importers import YAMLImporter
|
|
20
|
+
from cognite.neat.core._rules.transformers import VerifyDMSRules
|
|
21
21
|
|
|
22
22
|
raw_str = _read_source_file()
|
|
23
23
|
if org_name is not None:
|
|
@@ -4,10 +4,10 @@ from functools import lru_cache
|
|
|
4
4
|
from types import UnionType
|
|
5
5
|
from typing import Generic, TypeVar, Union, get_args, get_origin
|
|
6
6
|
|
|
7
|
-
from cognite.neat._constants import DEFAULT_NAMESPACE
|
|
8
|
-
from cognite.neat._rules._shared import ReadRules, Rules, VerifiedRules
|
|
9
|
-
from cognite.neat._rules.models import DMSInputRules, InformationInputRules
|
|
10
|
-
from cognite.neat._store._provenance import Agent as ProvenanceAgent
|
|
7
|
+
from cognite.neat.core._constants import DEFAULT_NAMESPACE
|
|
8
|
+
from cognite.neat.core._rules._shared import ReadRules, Rules, VerifiedRules
|
|
9
|
+
from cognite.neat.core._rules.models import DMSInputRules, InformationInputRules
|
|
10
|
+
from cognite.neat.core._store._provenance import Agent as ProvenanceAgent
|
|
11
11
|
|
|
12
12
|
T_RulesIn = TypeVar("T_RulesIn", bound=Rules)
|
|
13
13
|
T_RulesOut = TypeVar("T_RulesOut", bound=Rules)
|
|
@@ -16,9 +16,12 @@ from cognite.client.utils.useful_types import SequenceNotStr
|
|
|
16
16
|
from pydantic import ValidationError
|
|
17
17
|
from rdflib import Namespace
|
|
18
18
|
|
|
19
|
-
from cognite.neat._client import NeatClient
|
|
20
|
-
from cognite.neat._client.data_classes.data_modeling import
|
|
21
|
-
|
|
19
|
+
from cognite.neat.core._client import NeatClient
|
|
20
|
+
from cognite.neat.core._client.data_classes.data_modeling import (
|
|
21
|
+
ContainerApplyDict,
|
|
22
|
+
ViewApplyDict,
|
|
23
|
+
)
|
|
24
|
+
from cognite.neat.core._constants import (
|
|
22
25
|
COGNITE_CONCEPTS,
|
|
23
26
|
COGNITE_MODELS,
|
|
24
27
|
COGNITE_SPACES,
|
|
@@ -26,22 +29,25 @@ from cognite.neat._constants import (
|
|
|
26
29
|
DMS_RESERVED_PROPERTIES,
|
|
27
30
|
get_default_prefixes_and_namespaces,
|
|
28
31
|
)
|
|
29
|
-
from cognite.neat._issues import IssueList
|
|
30
|
-
from cognite.neat._issues._factory import from_pydantic_errors
|
|
31
|
-
from cognite.neat._issues.errors import CDFMissingClientError, NeatValueError
|
|
32
|
-
from cognite.neat._issues.warnings import
|
|
33
|
-
|
|
32
|
+
from cognite.neat.core._issues import IssueList
|
|
33
|
+
from cognite.neat.core._issues._factory import from_pydantic_errors
|
|
34
|
+
from cognite.neat.core._issues.errors import CDFMissingClientError, NeatValueError
|
|
35
|
+
from cognite.neat.core._issues.warnings import (
|
|
36
|
+
NeatValueWarning,
|
|
37
|
+
PropertyOverwritingWarning,
|
|
38
|
+
)
|
|
39
|
+
from cognite.neat.core._issues.warnings._models import (
|
|
34
40
|
SolutionModelBuildOnTopOfCDMWarning,
|
|
35
41
|
)
|
|
36
|
-
from cognite.neat._rules._constants import PATTERNS, get_reserved_words
|
|
37
|
-
from cognite.neat._rules._shared import (
|
|
42
|
+
from cognite.neat.core._rules._constants import PATTERNS, get_reserved_words
|
|
43
|
+
from cognite.neat.core._rules._shared import (
|
|
38
44
|
ReadInputRules,
|
|
39
45
|
ReadRules,
|
|
40
46
|
VerifiedRules,
|
|
41
47
|
)
|
|
42
|
-
from cognite.neat._rules.analysis import RulesAnalysis
|
|
43
|
-
from cognite.neat._rules.importers import DMSImporter
|
|
44
|
-
from cognite.neat._rules.models import (
|
|
48
|
+
from cognite.neat.core._rules.analysis import RulesAnalysis
|
|
49
|
+
from cognite.neat.core._rules.importers import DMSImporter
|
|
50
|
+
from cognite.neat.core._rules.models import (
|
|
45
51
|
DMSInputRules,
|
|
46
52
|
DMSRules,
|
|
47
53
|
InformationInputRules,
|
|
@@ -49,10 +55,22 @@ from cognite.neat._rules.models import (
|
|
|
49
55
|
SheetList,
|
|
50
56
|
data_types,
|
|
51
57
|
)
|
|
52
|
-
from cognite.neat._rules.models.data_types import
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
58
|
+
from cognite.neat.core._rules.models.data_types import (
|
|
59
|
+
AnyURI,
|
|
60
|
+
DataType,
|
|
61
|
+
Enum,
|
|
62
|
+
File,
|
|
63
|
+
String,
|
|
64
|
+
Timeseries,
|
|
65
|
+
)
|
|
66
|
+
from cognite.neat.core._rules.models.dms import (
|
|
67
|
+
DMSMetadata,
|
|
68
|
+
DMSProperty,
|
|
69
|
+
DMSValidation,
|
|
70
|
+
DMSView,
|
|
71
|
+
)
|
|
72
|
+
from cognite.neat.core._rules.models.dms._rules import DMSContainer, DMSEnum, DMSNode
|
|
73
|
+
from cognite.neat.core._rules.models.entities import (
|
|
56
74
|
ClassEntity,
|
|
57
75
|
ContainerEntity,
|
|
58
76
|
DMSUnknownEntity,
|
|
@@ -63,16 +81,22 @@ from cognite.neat._rules.models.entities import (
|
|
|
63
81
|
UnknownEntity,
|
|
64
82
|
ViewEntity,
|
|
65
83
|
)
|
|
66
|
-
from cognite.neat._rules.models.information import (
|
|
84
|
+
from cognite.neat.core._rules.models.information import (
|
|
67
85
|
InformationClass,
|
|
68
86
|
InformationInputClass,
|
|
69
87
|
InformationInputProperty,
|
|
70
88
|
InformationMetadata,
|
|
71
89
|
InformationProperty,
|
|
72
90
|
)
|
|
73
|
-
from cognite.neat._utils.rdf_ import get_inheritance_path
|
|
74
|
-
from cognite.neat._utils.spreadsheet import SpreadsheetRead
|
|
75
|
-
from cognite.neat._utils.text import
|
|
91
|
+
from cognite.neat.core._utils.rdf_ import get_inheritance_path
|
|
92
|
+
from cognite.neat.core._utils.spreadsheet import SpreadsheetRead
|
|
93
|
+
from cognite.neat.core._utils.text import (
|
|
94
|
+
NamingStandardization,
|
|
95
|
+
humanize_collection,
|
|
96
|
+
title,
|
|
97
|
+
to_camel_case,
|
|
98
|
+
to_words,
|
|
99
|
+
)
|
|
76
100
|
|
|
77
101
|
from ._base import RulesTransformer, T_VerifiedIn, T_VerifiedOut, VerifiedRulesTransformer
|
|
78
102
|
from ._verification import VerifyDMSRules
|
|
@@ -1370,7 +1394,7 @@ class _InformationRulesConverter:
|
|
|
1370
1394
|
def as_dms_rules(
|
|
1371
1395
|
self, ignore_undefined_value_types: bool = False, reserved_properties: Literal["error", "warning"] = "error"
|
|
1372
1396
|
) -> "DMSRules":
|
|
1373
|
-
from cognite.neat._rules.models.dms._rules import (
|
|
1397
|
+
from cognite.neat.core._rules.models.dms._rules import (
|
|
1374
1398
|
DMSContainer,
|
|
1375
1399
|
DMSProperty,
|
|
1376
1400
|
DMSRules,
|
|
@@ -1572,7 +1596,7 @@ class _InformationRulesConverter:
|
|
|
1572
1596
|
|
|
1573
1597
|
@classmethod
|
|
1574
1598
|
def _convert_metadata_to_dms(cls, metadata: InformationMetadata) -> "DMSMetadata":
|
|
1575
|
-
from cognite.neat._rules.models.dms._rules import (
|
|
1599
|
+
from cognite.neat.core._rules.models.dms._rules import (
|
|
1576
1600
|
DMSMetadata,
|
|
1577
1601
|
)
|
|
1578
1602
|
|
|
@@ -1598,7 +1622,7 @@ class _InformationRulesConverter:
|
|
|
1598
1622
|
edge_value_types_by_class_property_pair: dict[tuple[ClassEntity, str], ClassEntity],
|
|
1599
1623
|
end_node_by_edge: dict[ClassEntity, ClassEntity],
|
|
1600
1624
|
) -> "DMSProperty":
|
|
1601
|
-
from cognite.neat._rules.models.dms._rules import DMSProperty
|
|
1625
|
+
from cognite.neat.core._rules.models.dms._rules import DMSProperty
|
|
1602
1626
|
|
|
1603
1627
|
# returns property type, which can be ObjectProperty or DatatypeProperty
|
|
1604
1628
|
value_type = self._get_value_type(
|
|
@@ -1907,7 +1931,7 @@ class _DMSRulesConverter:
|
|
|
1907
1931
|
def as_information_rules(
|
|
1908
1932
|
self,
|
|
1909
1933
|
) -> "InformationRules":
|
|
1910
|
-
from cognite.neat._rules.models.information._rules import (
|
|
1934
|
+
from cognite.neat.core._rules.models.information._rules import (
|
|
1911
1935
|
InformationClass,
|
|
1912
1936
|
InformationProperty,
|
|
1913
1937
|
InformationRules,
|
|
@@ -1987,7 +2011,9 @@ class _DMSRulesConverter:
|
|
|
1987
2011
|
|
|
1988
2012
|
@classmethod
|
|
1989
2013
|
def _convert_metadata_to_info(cls, metadata: DMSMetadata) -> "InformationMetadata":
|
|
1990
|
-
from cognite.neat._rules.models.information._rules import
|
|
2014
|
+
from cognite.neat.core._rules.models.information._rules import (
|
|
2015
|
+
InformationMetadata,
|
|
2016
|
+
)
|
|
1991
2017
|
|
|
1992
2018
|
return InformationMetadata(
|
|
1993
2019
|
space=metadata.space,
|
|
@@ -5,13 +5,21 @@ from typing import Any, ClassVar, Literal
|
|
|
5
5
|
|
|
6
6
|
from cognite.client import data_modeling as dm
|
|
7
7
|
|
|
8
|
-
from cognite.neat._client import NeatClient
|
|
9
|
-
from cognite.neat._issues.errors import
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
from cognite.neat.
|
|
8
|
+
from cognite.neat.core._client import NeatClient
|
|
9
|
+
from cognite.neat.core._issues.errors import (
|
|
10
|
+
CDFMissingClientError,
|
|
11
|
+
NeatValueError,
|
|
12
|
+
ResourceNotFoundError,
|
|
13
|
+
)
|
|
14
|
+
from cognite.neat.core._issues.warnings import PropertyOverwritingWarning
|
|
15
|
+
from cognite.neat.core._rules.models import DMSRules, SheetList
|
|
16
|
+
from cognite.neat.core._rules.models.data_types import Enum
|
|
17
|
+
from cognite.neat.core._rules.models.dms import DMSContainer, DMSEnum, DMSProperty
|
|
18
|
+
from cognite.neat.core._rules.models.entities import (
|
|
19
|
+
ClassEntity,
|
|
20
|
+
ContainerEntity,
|
|
21
|
+
ViewEntity,
|
|
22
|
+
)
|
|
15
23
|
|
|
16
24
|
from ._base import VerifiedRulesTransformer
|
|
17
25
|
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
from abc import ABC
|
|
2
2
|
|
|
3
|
-
from cognite.neat._client import NeatClient
|
|
4
|
-
from cognite.neat._issues import MultiValueError, catch_issues
|
|
5
|
-
from cognite.neat._issues.errors import NeatTypeError, NeatValueError
|
|
6
|
-
from cognite.neat._rules._shared import (
|
|
3
|
+
from cognite.neat.core._client import NeatClient
|
|
4
|
+
from cognite.neat.core._issues import MultiValueError, catch_issues
|
|
5
|
+
from cognite.neat.core._issues.errors import NeatTypeError, NeatValueError
|
|
6
|
+
from cognite.neat.core._rules._shared import (
|
|
7
7
|
ReadRules,
|
|
8
8
|
T_ReadInputRules,
|
|
9
9
|
T_VerifiedRules,
|
|
10
10
|
VerifiedRules,
|
|
11
11
|
)
|
|
12
|
-
from cognite.neat._rules.models import (
|
|
12
|
+
from cognite.neat.core._rules.models import (
|
|
13
13
|
DMSInputRules,
|
|
14
14
|
DMSRules,
|
|
15
15
|
InformationInputRules,
|
|
16
16
|
InformationRules,
|
|
17
17
|
)
|
|
18
|
-
from cognite.neat._rules.models.dms import DMSValidation
|
|
19
|
-
from cognite.neat._rules.models.information import InformationValidation
|
|
18
|
+
from cognite.neat.core._rules.models.dms import DMSValidation
|
|
19
|
+
from cognite.neat.core._rules.models.information import InformationValidation
|
|
20
20
|
|
|
21
21
|
from ._base import RulesTransformer
|
|
22
22
|
|
|
@@ -12,16 +12,19 @@ from rdflib import Dataset, Graph, Namespace, URIRef
|
|
|
12
12
|
from rdflib.graph import DATASET_DEFAULT_GRAPH_ID
|
|
13
13
|
from rdflib.plugins.stores.sparqlstore import SPARQLUpdateStore
|
|
14
14
|
|
|
15
|
-
from cognite.neat._graph._shared import quad_formats, rdflib_to_oxi_type
|
|
16
|
-
from cognite.neat._graph.extractors import RdfFileExtractor, TripleExtractors
|
|
17
|
-
from cognite.neat._graph.queries import Queries
|
|
18
|
-
from cognite.neat._graph.transformers import Transformers
|
|
19
|
-
from cognite.neat._issues import IssueList, catch_issues
|
|
20
|
-
from cognite.neat._issues.errors import NeatValueError, OxigraphStorageLockedError
|
|
21
|
-
from cognite.neat._shared import InstanceType, Triple
|
|
22
|
-
from cognite.neat._utils.auxiliary import local_import
|
|
23
|
-
from cognite.neat._utils.rdf_ import
|
|
24
|
-
|
|
15
|
+
from cognite.neat.core._graph._shared import quad_formats, rdflib_to_oxi_type
|
|
16
|
+
from cognite.neat.core._graph.extractors import RdfFileExtractor, TripleExtractors
|
|
17
|
+
from cognite.neat.core._graph.queries import Queries
|
|
18
|
+
from cognite.neat.core._graph.transformers import Transformers
|
|
19
|
+
from cognite.neat.core._issues import IssueList, catch_issues
|
|
20
|
+
from cognite.neat.core._issues.errors import NeatValueError, OxigraphStorageLockedError
|
|
21
|
+
from cognite.neat.core._shared import InstanceType, Triple
|
|
22
|
+
from cognite.neat.core._utils.auxiliary import local_import
|
|
23
|
+
from cognite.neat.core._utils.rdf_ import (
|
|
24
|
+
add_triples_in_batch,
|
|
25
|
+
remove_namespace_from_uri,
|
|
26
|
+
)
|
|
27
|
+
from cognite.neat.core._utils.text import humanize_collection
|
|
25
28
|
|
|
26
29
|
from ._provenance import Change, Entity, Provenance
|
|
27
30
|
|
|
@@ -24,9 +24,9 @@ from typing import Any, Generic, TypeVar
|
|
|
24
24
|
|
|
25
25
|
from rdflib import PROV, RDF, Literal, URIRef
|
|
26
26
|
|
|
27
|
-
from cognite.neat._constants import CDF_NAMESPACE, DEFAULT_NAMESPACE
|
|
28
|
-
from cognite.neat._issues import IssueList
|
|
29
|
-
from cognite.neat._shared import FrozenNeatObject, NeatList, Triple
|
|
27
|
+
from cognite.neat.core._constants import CDF_NAMESPACE, DEFAULT_NAMESPACE
|
|
28
|
+
from cognite.neat.core._issues import IssueList
|
|
29
|
+
from cognite.neat.core._shared import FrozenNeatObject, NeatList, Triple
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
@dataclass(frozen=True)
|
|
@@ -10,18 +10,25 @@ from typing import Any, cast
|
|
|
10
10
|
import rdflib
|
|
11
11
|
from rdflib import URIRef
|
|
12
12
|
|
|
13
|
-
from cognite.neat._client import NeatClient
|
|
14
|
-
from cognite.neat._constants import DEFAULT_NAMESPACE
|
|
15
|
-
from cognite.neat._graph.extractors import
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
from cognite.neat.
|
|
20
|
-
from cognite.neat.
|
|
21
|
-
from cognite.neat._rules.
|
|
22
|
-
from cognite.neat._rules.
|
|
23
|
-
from cognite.neat._rules.
|
|
24
|
-
from cognite.neat.
|
|
13
|
+
from cognite.neat.core._client import NeatClient
|
|
14
|
+
from cognite.neat.core._constants import DEFAULT_NAMESPACE
|
|
15
|
+
from cognite.neat.core._graph.extractors import (
|
|
16
|
+
DMSGraphExtractor,
|
|
17
|
+
KnowledgeGraphExtractor,
|
|
18
|
+
)
|
|
19
|
+
from cognite.neat.core._issues import IssueList, catch_issues
|
|
20
|
+
from cognite.neat.core._issues.errors import NeatValueError
|
|
21
|
+
from cognite.neat.core._rules._shared import T_VerifiedRules, VerifiedRules
|
|
22
|
+
from cognite.neat.core._rules.exporters import BaseExporter
|
|
23
|
+
from cognite.neat.core._rules.exporters._base import CDFExporter, T_Export
|
|
24
|
+
from cognite.neat.core._rules.importers import BaseImporter
|
|
25
|
+
from cognite.neat.core._rules.models import DMSRules, InformationRules
|
|
26
|
+
from cognite.neat.core._rules.transformers import (
|
|
27
|
+
DMSToInformation,
|
|
28
|
+
VerifiedRulesTransformer,
|
|
29
|
+
VerifyAnyRules,
|
|
30
|
+
)
|
|
31
|
+
from cognite.neat.core._utils.upload import UploadResultList
|
|
25
32
|
|
|
26
33
|
from ._provenance import (
|
|
27
34
|
EXTERNAL_AGENT,
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
from dataclasses import dataclass
|
|
4
4
|
|
|
5
|
-
from cognite.neat._graph.extractors import KnowledgeGraphExtractor
|
|
6
|
-
from cognite.neat._issues import IssueList
|
|
7
|
-
from cognite.neat._rules.importers import BaseImporter
|
|
8
|
-
from cognite.neat._rules.transformers import VerifiedRulesTransformer
|
|
5
|
+
from cognite.neat.core._graph.extractors import KnowledgeGraphExtractor
|
|
6
|
+
from cognite.neat.core._issues import IssueList
|
|
7
|
+
from cognite.neat.core._rules.importers import BaseImporter
|
|
8
|
+
from cognite.neat.core._rules.transformers import VerifiedRulesTransformer
|
|
9
9
|
|
|
10
10
|
from ._provenance import Activity
|
|
11
11
|
|
|
File without changes
|
|
@@ -11,7 +11,7 @@ from cognite.client.config import global_config
|
|
|
11
11
|
from cognite.client.credentials import CredentialProvider, OAuthClientCredentials, OAuthInteractive, Token
|
|
12
12
|
|
|
13
13
|
from cognite.neat import _version
|
|
14
|
-
from cognite.neat._utils.auxiliary import local_import
|
|
14
|
+
from cognite.neat.core._utils.auxiliary import local_import
|
|
15
15
|
|
|
16
16
|
__all__ = ["EnvironmentVariables", "get_cognite_client"]
|
|
17
17
|
|
|
@@ -11,7 +11,7 @@ from typing import Any
|
|
|
11
11
|
|
|
12
12
|
from cognite.client.exceptions import CogniteDuplicatedError, CogniteReadTimeout
|
|
13
13
|
|
|
14
|
-
from cognite.neat._issues.errors import NeatImportError
|
|
14
|
+
from cognite.neat.core._issues.errors import NeatImportError
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
def local_import(module: str, extra: str) -> ModuleType:
|
|
@@ -2,8 +2,8 @@ from collections import Counter
|
|
|
2
2
|
from collections.abc import Iterable, Sequence
|
|
3
3
|
from typing import TypeVar
|
|
4
4
|
|
|
5
|
-
from cognite.neat._config import GLOBAL_CONFIG
|
|
6
|
-
from cognite.neat._constants import IN_PYODIDE
|
|
5
|
+
from cognite.neat.core._config import GLOBAL_CONFIG
|
|
6
|
+
from cognite.neat.core._constants import IN_PYODIDE
|
|
7
7
|
|
|
8
8
|
T_Element = TypeVar("T_Element")
|
|
9
9
|
|
|
@@ -7,7 +7,7 @@ from pydantic import HttpUrl, TypeAdapter, ValidationError
|
|
|
7
7
|
from rdflib import Graph, Namespace, URIRef
|
|
8
8
|
from rdflib import Literal as RdfLiteral
|
|
9
9
|
|
|
10
|
-
from cognite.neat._constants import SPACE_URI_PATTERN
|
|
10
|
+
from cognite.neat.core._constants import SPACE_URI_PATTERN
|
|
11
11
|
|
|
12
12
|
Triple: TypeAlias = tuple[URIRef, URIRef, RdfLiteral | URIRef]
|
|
13
13
|
|
|
@@ -8,7 +8,7 @@ from openpyxl import load_workbook
|
|
|
8
8
|
from openpyxl.worksheet.datavalidation import DataValidation
|
|
9
9
|
from openpyxl.worksheet.worksheet import Worksheet
|
|
10
10
|
|
|
11
|
-
from cognite.neat._rules._constants import get_internal_properties
|
|
11
|
+
from cognite.neat.core._rules._constants import get_internal_properties
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
@dataclass
|
|
@@ -148,10 +148,17 @@ def find_column_with_value(sheet: Worksheet, value: Any) -> str | None:
|
|
|
148
148
|
return None
|
|
149
149
|
|
|
150
150
|
|
|
151
|
-
def generate_data_validation(sheet: str, column: str,
|
|
152
|
-
"Creates openpyxl data validation object for a cell in a sheet
|
|
151
|
+
def generate_data_validation(sheet: str, column: str, total_header_rows: int, validation_range: int) -> DataValidation:
|
|
152
|
+
"""Creates openpyxl data validation object for a cell in a sheet
|
|
153
|
+
|
|
154
|
+
Args:
|
|
155
|
+
sheet: The name of the sheet where the data validation is applied.
|
|
156
|
+
column: The column letter where the data validation is applied.
|
|
157
|
+
total_header_rows: The number of header rows in the sheet.
|
|
158
|
+
validation_range: The total number of validation values in the column.
|
|
159
|
+
"""
|
|
153
160
|
|
|
154
161
|
return DataValidation(
|
|
155
162
|
type="list",
|
|
156
|
-
formula1=f"={sheet}!{column}${
|
|
163
|
+
formula1=f"={sheet}!{column}${total_header_rows + 1}:{column}${validation_range + total_header_rows + 1}",
|
|
157
164
|
)
|
|
@@ -3,9 +3,9 @@ from dataclasses import dataclass, field
|
|
|
3
3
|
from functools import total_ordering
|
|
4
4
|
from typing import Any, Generic
|
|
5
5
|
|
|
6
|
-
from cognite.neat._issues import IssueList
|
|
7
|
-
from cognite.neat._issues.errors import NeatValueError
|
|
8
|
-
from cognite.neat._shared import T_ID, NeatList, NeatObject
|
|
6
|
+
from cognite.neat.core._issues import IssueList
|
|
7
|
+
from cognite.neat.core._issues.errors import NeatValueError
|
|
8
|
+
from cognite.neat.core._shared import T_ID, NeatList, NeatObject
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
@total_ordering
|
|
@@ -5,22 +5,22 @@ from cognite.client import CogniteClient
|
|
|
5
5
|
from cognite.client import data_modeling as dm
|
|
6
6
|
|
|
7
7
|
from cognite.neat import _version
|
|
8
|
-
from cognite.neat._client import NeatClient
|
|
9
|
-
from cognite.neat._issues import IssueList
|
|
10
|
-
from cognite.neat._issues.errors import RegexViolationError
|
|
11
|
-
from cognite.neat._issues.errors._general import NeatImportError
|
|
12
|
-
from cognite.neat._rules import importers
|
|
13
|
-
from cognite.neat._rules.models import DMSRules
|
|
14
|
-
from cognite.neat._rules.models.information._rules import InformationRules
|
|
15
|
-
from cognite.neat._rules.transformers import (
|
|
8
|
+
from cognite.neat.core._client import NeatClient
|
|
9
|
+
from cognite.neat.core._issues import IssueList
|
|
10
|
+
from cognite.neat.core._issues.errors import RegexViolationError
|
|
11
|
+
from cognite.neat.core._issues.errors._general import NeatImportError
|
|
12
|
+
from cognite.neat.core._rules import importers
|
|
13
|
+
from cognite.neat.core._rules.models import DMSRules
|
|
14
|
+
from cognite.neat.core._rules.models.information._rules import InformationRules
|
|
15
|
+
from cognite.neat.core._rules.transformers import (
|
|
16
16
|
InformationToDMS,
|
|
17
17
|
MergeDMSRules,
|
|
18
18
|
MergeInformationRules,
|
|
19
19
|
ToDMSCompliantEntities,
|
|
20
20
|
VerifyInformationRules,
|
|
21
21
|
)
|
|
22
|
-
from cognite.neat._store._rules_store import RulesEntity
|
|
23
|
-
from cognite.neat._utils.auxiliary import local_import
|
|
22
|
+
from cognite.neat.core._store._rules_store import RulesEntity
|
|
23
|
+
from cognite.neat.core._utils.auxiliary import local_import
|
|
24
24
|
|
|
25
25
|
from ._collector import _COLLECTOR, Collector
|
|
26
26
|
from ._drop import DropAPI
|
|
@@ -10,8 +10,8 @@ from typing import Any
|
|
|
10
10
|
|
|
11
11
|
from mixpanel import Consumer, Mixpanel # type: ignore[import-untyped]
|
|
12
12
|
|
|
13
|
-
from cognite.neat._constants import IN_NOTEBOOK, IN_PYODIDE
|
|
14
13
|
from cognite.neat._version import __version__
|
|
14
|
+
from cognite.neat.core._constants import IN_NOTEBOOK, IN_PYODIDE
|
|
15
15
|
|
|
16
16
|
_NEAT_MIXPANEL_TOKEN: str = "bd630ad149d19999df3989c3a3750c4f"
|
|
17
17
|
|
|
@@ -5,9 +5,9 @@ from typing import Literal
|
|
|
5
5
|
from cognite.client.utils.useful_types import SequenceNotStr
|
|
6
6
|
from rdflib import URIRef
|
|
7
7
|
|
|
8
|
-
from cognite.neat._constants import COGNITE_MODELS
|
|
9
|
-
from cognite.neat._issues import IssueList
|
|
10
|
-
from cognite.neat._rules.transformers import DropModelViews
|
|
8
|
+
from cognite.neat.core._constants import COGNITE_MODELS
|
|
9
|
+
from cognite.neat.core._issues import IssueList
|
|
10
|
+
from cognite.neat.core._rules.transformers import DropModelViews
|
|
11
11
|
|
|
12
12
|
from ._state import SessionState
|
|
13
13
|
from .exceptions import NeatSessionError, session_class_wrapper
|
|
@@ -3,8 +3,8 @@ from typing import cast
|
|
|
3
3
|
import pandas as pd
|
|
4
4
|
from rdflib import URIRef
|
|
5
5
|
|
|
6
|
-
from cognite.neat._utils.rdf_ import remove_namespace_from_uri
|
|
7
|
-
from cognite.neat._utils.text import humanize_collection
|
|
6
|
+
from cognite.neat.core._utils.rdf_ import remove_namespace_from_uri
|
|
7
|
+
from cognite.neat.core._utils.text import humanize_collection
|
|
8
8
|
|
|
9
9
|
from ._state import SessionState
|
|
10
10
|
from .exceptions import NeatSessionError, session_class_wrapper
|
|
@@ -4,9 +4,13 @@ from typing import Literal, overload
|
|
|
4
4
|
|
|
5
5
|
import pandas as pd
|
|
6
6
|
|
|
7
|
-
from cognite.neat._constants import IN_NOTEBOOK
|
|
8
|
-
from cognite.neat._issues import IssueList
|
|
9
|
-
from cognite.neat._utils.upload import
|
|
7
|
+
from cognite.neat.core._constants import IN_NOTEBOOK
|
|
8
|
+
from cognite.neat.core._issues import IssueList
|
|
9
|
+
from cognite.neat.core._utils.upload import (
|
|
10
|
+
UploadResult,
|
|
11
|
+
UploadResultCore,
|
|
12
|
+
UploadResultList,
|
|
13
|
+
)
|
|
10
14
|
|
|
11
15
|
from ._state import SessionState
|
|
12
16
|
from .exceptions import session_class_wrapper
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
from cognite.neat._issues import IssueList
|
|
2
|
-
from cognite.neat._rules.models.mapping import load_classic_to_core_mapping
|
|
3
|
-
from cognite.neat._rules.transformers import (
|
|
1
|
+
from cognite.neat.core._issues import IssueList
|
|
2
|
+
from cognite.neat.core._rules.models.mapping import load_classic_to_core_mapping
|
|
3
|
+
from cognite.neat.core._rules.transformers import (
|
|
4
4
|
AsParentPropertyId,
|
|
5
5
|
ChangeViewPrefix,
|
|
6
6
|
IncludeReferenced,
|