wizata-dsapi 1.1.47__tar.gz → 1.2.1__tar.gz

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.
Files changed (55) hide show
  1. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/PKG-INFO +1 -1
  2. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/__init__.py +2 -1
  3. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/datastore.py +1 -1
  4. wizata_dsapi-1.2.1/wizata_dsapi/streamlit_utils.py +68 -0
  5. wizata_dsapi-1.2.1/wizata_dsapi/version.py +1 -0
  6. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi.egg-info/PKG-INFO +1 -1
  7. wizata_dsapi-1.1.47/wizata_dsapi/streamlit_utils.py +0 -17
  8. wizata_dsapi-1.1.47/wizata_dsapi/version.py +0 -1
  9. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/LICENSE.txt +0 -0
  10. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/README.rst +0 -0
  11. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/setup.cfg +0 -0
  12. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/setup.py +0 -0
  13. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/api_config.py +0 -0
  14. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/api_dto.py +0 -0
  15. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/api_interface.py +0 -0
  16. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/bucket.py +0 -0
  17. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/business_label.py +0 -0
  18. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/context.py +0 -0
  19. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/dataframe_toolkit.py +0 -0
  20. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/datapoint.py +0 -0
  21. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/ds_dataframe.py +0 -0
  22. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/dsapi_json_encoder.py +0 -0
  23. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/evaluation.py +0 -0
  24. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/execution.py +0 -0
  25. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/experiment.py +0 -0
  26. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/group_system.py +0 -0
  27. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/ilogger.py +0 -0
  28. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/insight.py +0 -0
  29. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/mlmodel.py +0 -0
  30. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/model_toolkit.py +0 -0
  31. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/models/__init__.py +0 -0
  32. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/models/common.py +0 -0
  33. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/paged_query_result.py +0 -0
  34. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/pipeline.py +0 -0
  35. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/pipeline_image.py +0 -0
  36. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/plot.py +0 -0
  37. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/plots/__init__.py +0 -0
  38. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/plots/common.py +0 -0
  39. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/request.py +0 -0
  40. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/script.py +0 -0
  41. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/scripts/__init__.py +0 -0
  42. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/scripts/common.py +0 -0
  43. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/solution_component.py +0 -0
  44. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/template.py +0 -0
  45. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/trigger.py +0 -0
  46. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/twin.py +0 -0
  47. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/twinregistration.py +0 -0
  48. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/wizard_function.py +0 -0
  49. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/wizard_request.py +0 -0
  50. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/wizata_dsapi_client.py +0 -0
  51. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi/words.py +0 -0
  52. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi.egg-info/SOURCES.txt +0 -0
  53. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi.egg-info/dependency_links.txt +0 -0
  54. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi.egg-info/requires.txt +0 -0
  55. {wizata_dsapi-1.1.47 → wizata_dsapi-1.2.1}/wizata_dsapi.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wizata_dsapi
3
- Version: 1.1.47
3
+ Version: 1.2.1
4
4
  Summary: Wizata Data Science Toolkit
5
5
  Author: Wizata S.A.
6
6
  Author-email: info@wizata.com
@@ -45,4 +45,5 @@ from .pipeline_image import PipelineImage
45
45
  from .evaluation import Evaluation
46
46
 
47
47
  # Streamlit utils
48
- from .streamlit_utils import get_streamlit_token, get_streamlit_domain
48
+ from .streamlit_utils import (get_streamlit_token, get_streamlit_domain, get_streamlit_from, get_streamlit_to,
49
+ get_streamlit_twin_id)
@@ -5,7 +5,7 @@ class DataStore(ApiDto):
5
5
 
6
6
  @classmethod
7
7
  def route(cls):
8
- return "datastore"
8
+ return "datastores"
9
9
 
10
10
  @classmethod
11
11
  def from_dict(cls, data):
@@ -0,0 +1,68 @@
1
+ import sys
2
+ import uuid
3
+ from typing import Optional
4
+ from uuid import UUID
5
+
6
+ from .dataframe_toolkit import generate_epoch
7
+
8
+
9
+ def get_streamlit_token():
10
+ if 'streamlit' in sys.modules:
11
+ st = sys.modules['streamlit']
12
+ if st.query_params is not None and "auth_token" in st.query_params:
13
+ auth_token = st.query_params["auth_token"]
14
+ return auth_token
15
+ return None
16
+
17
+
18
+ def get_streamlit_domain():
19
+ if 'streamlit' in sys.modules:
20
+ st = sys.modules['streamlit']
21
+ if st.query_params is not None and "dsapi" in st.query_params:
22
+ domain = st.query_params["dsapi"]
23
+ return domain
24
+ return None
25
+
26
+ def get_streamlit_twin_id() -> Optional[UUID]:
27
+ """
28
+ return current selected twin_id.
29
+ :return:
30
+ """
31
+ if 'streamlit' in sys.modules:
32
+ st = sys.modules['streamlit']
33
+ if st.query_params is not None and "twin_id" in st.query_params:
34
+ twin_id = uuid.UUID(st.query_params["twin_id"])
35
+ return twin_id
36
+ return None
37
+
38
+
39
+ def get_streamlit_from() -> Optional[int]:
40
+ """
41
+ timestamp representation of from parameter on UI (ms)
42
+ :return:
43
+ """
44
+ if 'streamlit' in sys.modules:
45
+ st = sys.modules['streamlit']
46
+ if st.query_params is not None and "from" in st.query_params:
47
+ param = st.query_params["from"]
48
+ if 'now' in param:
49
+ return generate_epoch(param)
50
+ else:
51
+ return int(param)
52
+ return None
53
+
54
+
55
+ def get_streamlit_to() -> Optional[int]:
56
+ """
57
+ timestamp representation of to parameter on UI (ms)
58
+ :return:
59
+ """
60
+ if 'streamlit' in sys.modules:
61
+ st = sys.modules['streamlit']
62
+ if st.query_params is not None and "to" in st.query_params:
63
+ param = st.query_params["to"]
64
+ if 'now' in param:
65
+ return generate_epoch(param)
66
+ else:
67
+ return int(param)
68
+ return None
@@ -0,0 +1 @@
1
+ __version__ = "1.2.1"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wizata-dsapi
3
- Version: 1.1.47
3
+ Version: 1.2.1
4
4
  Summary: Wizata Data Science Toolkit
5
5
  Author: Wizata S.A.
6
6
  Author-email: info@wizata.com
@@ -1,17 +0,0 @@
1
- import sys
2
-
3
-
4
- def get_streamlit_token():
5
- if 'streamlit' in sys.modules:
6
- st = sys.modules['streamlit']
7
- if st.query_params is not None and "auth_token" in st.query_params:
8
- auth_token = st.query_params["auth_token"]
9
- return auth_token
10
-
11
-
12
- def get_streamlit_domain():
13
- if 'streamlit' in sys.modules:
14
- st = sys.modules['streamlit']
15
- if st.query_params is not None and "dsapi" in st.query_params:
16
- domain = st.query_params["dsapi"]
17
- return domain
@@ -1 +0,0 @@
1
- __version__ = "1.1.47"
File without changes
File without changes
File without changes
File without changes