polytope-python 1.0.11__tar.gz → 1.0.13__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 (57) hide show
  1. {polytope-python-1.0.11/polytope_python.egg-info → polytope-python-1.0.13}/PKG-INFO +1 -1
  2. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/backends/fdb.py +10 -0
  3. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/options.py +2 -5
  4. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/shapes.py +1 -1
  5. polytope-python-1.0.13/polytope_feature/version.py +1 -0
  6. {polytope-python-1.0.11 → polytope-python-1.0.13/polytope_python.egg-info}/PKG-INFO +1 -1
  7. polytope-python-1.0.11/polytope_feature/version.py +0 -1
  8. {polytope-python-1.0.11 → polytope-python-1.0.13}/LICENSE +0 -0
  9. {polytope-python-1.0.11 → polytope-python-1.0.13}/MANIFEST.in +0 -0
  10. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/__init__.py +0 -0
  11. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/__init__.py +0 -0
  12. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/backends/__init__.py +0 -0
  13. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/backends/datacube.py +0 -0
  14. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/backends/mock.py +0 -0
  15. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/backends/xarray.py +0 -0
  16. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/datacube_axis.py +0 -0
  17. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/index_tree_pb2.py +0 -0
  18. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/tensor_index_tree.py +0 -0
  19. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/__init__.py +0 -0
  20. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_cyclic/__init__.py +0 -0
  21. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_cyclic/datacube_cyclic.py +0 -0
  22. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/__init__.py +0 -0
  23. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/datacube_mappers.py +0 -0
  24. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/__init__.py +0 -0
  25. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/healpix.py +0 -0
  26. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/healpix_nested.py +0 -0
  27. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/local_regular.py +0 -0
  28. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/octahedral.py +0 -0
  29. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/reduced_ll.py +0 -0
  30. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_mappers/mapper_types/regular.py +0 -0
  31. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_merger/__init__.py +0 -0
  32. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_merger/datacube_merger.py +0 -0
  33. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_reverse/__init__.py +0 -0
  34. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_reverse/datacube_reverse.py +0 -0
  35. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_transformations.py +0 -0
  36. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_type_change/__init__.py +0 -0
  37. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/transformations/datacube_type_change/datacube_type_change.py +0 -0
  38. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/datacube/tree_encoding.py +0 -0
  39. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/engine/__init__.py +0 -0
  40. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/engine/engine.py +0 -0
  41. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/engine/hullslicer.py +0 -0
  42. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/polytope.py +0 -0
  43. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/__init__.py +0 -0
  44. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/combinatorics.py +0 -0
  45. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/exceptions.py +0 -0
  46. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/geometry.py +0 -0
  47. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/list_tools.py +0 -0
  48. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_feature/utility/profiling.py +0 -0
  49. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_python.egg-info/SOURCES.txt +0 -0
  50. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_python.egg-info/dependency_links.txt +0 -0
  51. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_python.egg-info/not-zip-safe +0 -0
  52. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_python.egg-info/requires.txt +0 -0
  53. {polytope-python-1.0.11 → polytope-python-1.0.13}/polytope_python.egg-info/top_level.txt +0 -0
  54. {polytope-python-1.0.11 → polytope-python-1.0.13}/pyproject.toml +0 -0
  55. {polytope-python-1.0.11 → polytope-python-1.0.13}/requirements.txt +0 -0
  56. {polytope-python-1.0.11 → polytope-python-1.0.13}/setup.cfg +0 -0
  57. {polytope-python-1.0.11 → polytope-python-1.0.13}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 1.0
2
2
  Name: polytope-python
3
- Version: 1.0.11
3
+ Version: 1.0.13
4
4
  Summary: Polytope datacube feature extraction library
5
5
  Home-page: https://github.com/ecmwf/polytope
6
6
  Author: ECMWF
@@ -29,7 +29,9 @@ class FDBDatacube(Datacube):
29
29
 
30
30
  self.gj = gj
31
31
  if len(alternative_axes) == 0:
32
+ logging.info("Find GribJump axes for %s", context)
32
33
  self.fdb_coordinates = self.gj.axes(partial_request, ctx=context)
34
+ logging.info("Retrieved available GribJump axes for %s", context)
33
35
  if len(self.fdb_coordinates) == 0:
34
36
  raise BadRequestError(partial_request)
35
37
  else:
@@ -37,6 +39,12 @@ class FDBDatacube(Datacube):
37
39
  for axis_config in alternative_axes:
38
40
  self.fdb_coordinates[axis_config.axis_name] = axis_config.values
39
41
 
42
+ fdb_coordinates_copy = deepcopy(self.fdb_coordinates)
43
+ for axis, vals in fdb_coordinates_copy.items():
44
+ if len(vals) == 1:
45
+ if vals[0] == "":
46
+ self.fdb_coordinates.pop(axis)
47
+
40
48
  logging.info("Axes returned from GribJump are: " + str(self.fdb_coordinates))
41
49
 
42
50
  self.fdb_coordinates["values"] = []
@@ -117,7 +125,9 @@ class FDBDatacube(Datacube):
117
125
  complete_list_complete_uncompressed_requests.append(complete_uncompressed_request)
118
126
  complete_fdb_decoding_info.append(fdb_requests_decoding_info[j])
119
127
  logging.debug("The requests we give GribJump are: %s", complete_list_complete_uncompressed_requests)
128
+ logging.info("Requests given to GribJump extract for %s", context)
120
129
  output_values = self.gj.extract(complete_list_complete_uncompressed_requests, context)
130
+ logging.info("Requests extracted from GribJump for %s", context)
121
131
  logging.debug("GribJump outputs: %s", output_values)
122
132
  self.assign_fdb_output_to_nodes(output_values, complete_fdb_decoding_info)
123
133
 
@@ -1,8 +1,7 @@
1
- import argparse
2
1
  from abc import ABC
3
2
  from typing import Dict, List, Literal, Optional, Union
4
3
 
5
- from conflator import ConfigModel, Conflator
4
+ from conflator import ConfigModel
6
5
  from pydantic import ConfigDict
7
6
 
8
7
 
@@ -68,9 +67,7 @@ class Config(ConfigModel):
68
67
  class PolytopeOptions(ABC):
69
68
  @staticmethod
70
69
  def get_polytope_options(options):
71
- parser = argparse.ArgumentParser(allow_abbrev=False)
72
- conflator = Conflator(app_name="polytope", model=Config, cli=False, argparser=parser, **options)
73
- config_options = conflator.load()
70
+ config_options = Config.model_validate(options)
74
71
 
75
72
  axis_config = config_options.axis_config
76
73
  compressed_axes_config = config_options.compressed_axes_config
@@ -26,7 +26,7 @@ class ConvexPolytope(Shape):
26
26
  def __init__(self, axes, points, method=None, is_orthogonal=False):
27
27
  self._axes = list(axes)
28
28
  self.is_flat = False
29
- if len(self._axes) == 1:
29
+ if len(self._axes) == 1 and len(points) == 1:
30
30
  self.is_flat = True
31
31
  self.points = points
32
32
  self.method = method
@@ -0,0 +1 @@
1
+ __version__ = "1.0.13"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 1.0
2
2
  Name: polytope-python
3
- Version: 1.0.11
3
+ Version: 1.0.13
4
4
  Summary: Polytope datacube feature extraction library
5
5
  Home-page: https://github.com/ecmwf/polytope
6
6
  Author: ECMWF
@@ -1 +0,0 @@
1
- __version__ = "1.0.11"