sacc 0.12__tar.gz → 0.14__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. {sacc-0.12 → sacc-0.14}/.github/workflows/desc-ci.yml +1 -2
  2. {sacc-0.12 → sacc-0.14}/.readthedocs.yml +7 -2
  3. {sacc-0.12/sacc.egg-info → sacc-0.14}/PKG-INFO +5 -2
  4. {sacc-0.12 → sacc-0.14}/README.md +1 -1
  5. sacc-0.12/sacc.egg-info/requires.txt → sacc-0.14/doc/requirements.txt +3 -2
  6. {sacc-0.12 → sacc-0.14}/sacc/__init__.py +1 -1
  7. {sacc-0.12 → sacc-0.14}/sacc/sacc.py +15 -0
  8. {sacc-0.12 → sacc-0.14}/sacc/windows.py +2 -1
  9. {sacc-0.12 → sacc-0.14/sacc.egg-info}/PKG-INFO +5 -2
  10. {sacc-0.12 → sacc-0.14}/sacc.egg-info/SOURCES.txt +1 -0
  11. sacc-0.14/sacc.egg-info/requires.txt +13 -0
  12. {sacc-0.12 → sacc-0.14}/setup.py +8 -0
  13. {sacc-0.12 → sacc-0.14}/test/test_sacc2.py +6 -0
  14. {sacc-0.12 → sacc-0.14}/.git_archival.txt +0 -0
  15. {sacc-0.12 → sacc-0.14}/.gitattributes +0 -0
  16. {sacc-0.12 → sacc-0.14}/.github/workflows/publish.yml +0 -0
  17. {sacc-0.12 → sacc-0.14}/.gitignore +0 -0
  18. {sacc-0.12 → sacc-0.14}/LICENSE +0 -0
  19. {sacc-0.12 → sacc-0.14}/MANIFEST.in +0 -0
  20. {sacc-0.12 → sacc-0.14}/doc/Makefile +0 -0
  21. {sacc-0.12 → sacc-0.14}/doc/format.md +0 -0
  22. {sacc-0.12 → sacc-0.14}/doc/source/Makefile +0 -0
  23. {sacc-0.12 → sacc-0.14}/doc/source/api.rst +0 -0
  24. {sacc-0.12 → sacc-0.14}/doc/source/conf.py +0 -0
  25. {sacc-0.12 → sacc-0.14}/doc/source/covariance.rst +0 -0
  26. {sacc-0.12 → sacc-0.14}/doc/source/data_types.rst +0 -0
  27. {sacc-0.12 → sacc-0.14}/doc/source/index.rst +0 -0
  28. {sacc-0.12 → sacc-0.14}/doc/source/intro.rst +0 -0
  29. {sacc-0.12 → sacc-0.14}/doc/source/sacc.rst +0 -0
  30. {sacc-0.12 → sacc-0.14}/doc/source/tracers.rst +0 -0
  31. {sacc-0.12 → sacc-0.14}/doc/source/utils.rst +0 -0
  32. {sacc-0.12 → sacc-0.14}/doc/source/windows.rst +0 -0
  33. {sacc-0.12 → sacc-0.14}/examples/.gitignore +0 -0
  34. {sacc-0.12 → sacc-0.14}/examples/CMB_LSS_read.ipynb +0 -0
  35. {sacc-0.12 → sacc-0.14}/examples/CMB_LSS_write.ipynb +0 -0
  36. {sacc-0.12 → sacc-0.14}/examples/Convert_DES_Sacc.ipynb +0 -0
  37. {sacc-0.12 → sacc-0.14}/examples/Convert_KIDS_Sacc.ipynb +0 -0
  38. {sacc-0.12 → sacc-0.14}/examples/Create_Sacc.ipynb +0 -0
  39. {sacc-0.12 → sacc-0.14}/examples/README.md +0 -0
  40. {sacc-0.12 → sacc-0.14}/examples/SACC_for_clusters.ipynb +0 -0
  41. {sacc-0.12 → sacc-0.14}/examples/SACC_read.ipynb +0 -0
  42. {sacc-0.12 → sacc-0.14}/examples/SACC_write.ipynb +0 -0
  43. {sacc-0.12 → sacc-0.14}/examples/demo_sacc_for_clusters_N+M.ipynb +0 -0
  44. {sacc-0.12 → sacc-0.14}/examples/example-txpipe-sacc1.sacc +0 -0
  45. {sacc-0.12 → sacc-0.14}/requirements.txt +0 -0
  46. {sacc-0.12 → sacc-0.14}/sacc/covariance.py +0 -0
  47. {sacc-0.12 → sacc-0.14}/sacc/data_types.py +0 -0
  48. {sacc-0.12 → sacc-0.14}/sacc/tracers.py +0 -0
  49. {sacc-0.12 → sacc-0.14}/sacc/utils.py +0 -0
  50. {sacc-0.12 → sacc-0.14}/sacc.egg-info/dependency_links.txt +0 -0
  51. {sacc-0.12 → sacc-0.14}/sacc.egg-info/top_level.txt +0 -0
  52. {sacc-0.12 → sacc-0.14}/setup.cfg +0 -0
  53. {sacc-0.12 → sacc-0.14}/test/data/.gitignore +0 -0
  54. {sacc-0.12 → sacc-0.14}/test/make_test_data.py +0 -0
  55. {sacc-0.12 → sacc-0.14}/test/test_cluster_data_tracers.py +0 -0
@@ -26,8 +26,7 @@ jobs:
26
26
  - name: Dependencies
27
27
  run: |
28
28
  python -m pip install --upgrade numpy pytest
29
- python -m pip install -r requirements.txt
30
- python setup.py install
29
+ python -m pip install '.[all]'
31
30
 
32
31
  - name: Run tests
33
32
  run: |
@@ -16,6 +16,11 @@ sphinx:
16
16
 
17
17
  # Optionally set the version of Python and requirements required to build your docs
18
18
  python:
19
- version: 3.7
20
19
  install:
21
- - requirements: requirements.txt
20
+ - requirements: doc/requirements.txt
21
+
22
+
23
+ build:
24
+ os: "ubuntu-22.04"
25
+ tools:
26
+ python: "3.9"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sacc
3
- Version: 0.12
3
+ Version: 0.14
4
4
  Summary: SACC - the LSST/DESC summary statistic data format library
5
5
  Home-page: https://github.com/LSSTDESC/sacc
6
6
  Author: LSST DESC
@@ -8,6 +8,9 @@ Author-email: joezuntz@googlemail.com
8
8
  License: UNKNOWN
9
9
  Platform: UNKNOWN
10
10
  Description-Content-Type: text/markdown
11
+ Provides-Extra: all
12
+ Provides-Extra: doc
13
+ Provides-Extra: qp
11
14
  License-File: LICENSE
12
15
 
13
16
  Sacc
@@ -42,7 +45,7 @@ If you have a problem you've not been able to debug, or a feature request/sugges
42
45
  Versions
43
46
  --------
44
47
 
45
- The current release is [version 0.8](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
48
+ The current release is [version 0.12](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
46
49
 
47
50
  You can find a list of [previous releases here](https://github.com/LSSTDESC/sacc/releases). The releases above 0.2 are all backwards compatible; 0.1 is a previous version of the format.
48
51
 
@@ -30,7 +30,7 @@ If you have a problem you've not been able to debug, or a feature request/sugges
30
30
  Versions
31
31
  --------
32
32
 
33
- The current release is [version 0.8](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
33
+ The current release is [version 0.12](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
34
34
 
35
35
  You can find a list of [previous releases here](https://github.com/LSSTDESC/sacc/releases). The releases above 0.2 are all backwards compatible; 0.1 is a previous version of the format.
36
36
 
@@ -1,5 +1,6 @@
1
- astropy
1
+ scipy
2
2
  numpy>=1.20
3
3
  numpydoc
4
+ astropy
4
5
  qp-prob
5
- scipy
6
+ sphinx==6.*
@@ -3,4 +3,4 @@ from .windows import Window, BandpowerWindow, TopHatWindow, LogTopHatWindow # n
3
3
  from .data_types import standard_types, parse_data_type_name, build_data_type_name # noqa
4
4
  from .tracers import BaseTracer # noqa
5
5
  from .covariance import BaseCovariance # noqa
6
- __version__ = '0.12' #noqa
6
+ __version__ = '0.13' #noqa
@@ -623,6 +623,21 @@ class Sacc:
623
623
 
624
624
  return data_types
625
625
 
626
+ def has_tracer(self, name):
627
+ """
628
+ Determine whether a tracer object with the given name is present
629
+
630
+ Parameters
631
+ ----------
632
+ name: str
633
+ A string name of a tracer
634
+
635
+ Returns
636
+ -------
637
+ value: True if the tracer exists, else False
638
+ """
639
+ return name in self.tracers
640
+
626
641
  def get_tracer(self, name):
627
642
  """
628
643
  Get the tracer object with the given name
@@ -51,7 +51,8 @@ class BaseWindow:
51
51
  # Pull out the relevant objects for this subclass.
52
52
  # Note that we can't use isinstance here.
53
53
  windows = [w for w in instance_list if type(w) == subcls]
54
- tables += subcls.to_tables(windows)
54
+ if len(windows) > 0:
55
+ tables += subcls.to_tables(windows)
55
56
  return tables
56
57
 
57
58
  @classmethod
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sacc
3
- Version: 0.12
3
+ Version: 0.14
4
4
  Summary: SACC - the LSST/DESC summary statistic data format library
5
5
  Home-page: https://github.com/LSSTDESC/sacc
6
6
  Author: LSST DESC
@@ -8,6 +8,9 @@ Author-email: joezuntz@googlemail.com
8
8
  License: UNKNOWN
9
9
  Platform: UNKNOWN
10
10
  Description-Content-Type: text/markdown
11
+ Provides-Extra: all
12
+ Provides-Extra: doc
13
+ Provides-Extra: qp
11
14
  License-File: LICENSE
12
15
 
13
16
  Sacc
@@ -42,7 +45,7 @@ If you have a problem you've not been able to debug, or a feature request/sugges
42
45
  Versions
43
46
  --------
44
47
 
45
- The current release is [version 0.8](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
48
+ The current release is [version 0.12](https://github.com/LSSTDESC/sacc/releases/tag/0.12).
46
49
 
47
50
  You can find a list of [previous releases here](https://github.com/LSSTDESC/sacc/releases). The releases above 0.2 are all backwards compatible; 0.1 is a previous version of the format.
48
51
 
@@ -11,6 +11,7 @@ setup.py
11
11
  .github/workflows/publish.yml
12
12
  doc/Makefile
13
13
  doc/format.md
14
+ doc/requirements.txt
14
15
  doc/source/Makefile
15
16
  doc/source/api.rst
16
17
  doc/source/conf.py
@@ -0,0 +1,13 @@
1
+ astropy
2
+ numpy>=1.20
3
+ scipy
4
+
5
+ [all]
6
+ numpydoc
7
+ qp-prob[all]
8
+
9
+ [doc]
10
+ numpydoc
11
+
12
+ [qp]
13
+ qp-prob[all]
@@ -6,6 +6,9 @@ description = "SACC - the LSST/DESC summary statistic data format library"
6
6
  with open('requirements.txt') as f:
7
7
  requirements = f.read().splitlines()
8
8
 
9
+ requirements.remove("qp-prob")
10
+ requirements.remove("numpydoc")
11
+
9
12
  with open('README.md') as f:
10
13
  long_description = f.read()
11
14
 
@@ -19,5 +22,10 @@ setup(name="sacc",
19
22
  use_scm_version=True,
20
23
  setup_requires=["setuptools_scm<7.0", "setuptools_scm_git_archive"],
21
24
  install_requires=requirements,
25
+ extras_require = {
26
+ 'all': ["qp-prob[all]", "numpydoc"],
27
+ 'doc': ["numpydoc"],
28
+ 'qp': ["qp-prob[all]"],
29
+ },
22
30
  packages=['sacc'],
23
31
  )
@@ -876,3 +876,9 @@ def test_io_qp():
876
876
  mu = s2.get_mean(sacc.standard_types.galaxy_shear_cl_ee)
877
877
  for i in range(20):
878
878
  assert mu[i] == 0.1 * i
879
+
880
+ def test_sacc_has_tracer():
881
+ s = get_filled_sacc()
882
+ assert not s.has_tracer("this_is_not_a_tracer")
883
+ for tracer_name in ['source_0', 'source_1', 'source_2']:
884
+ assert s.has_tracer(tracer_name)
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes