PyTransit 2.6.8__tar.gz → 2.6.9__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 (148) hide show
  1. {pytransit-2.6.8 → pytransit-2.6.9}/PKG-INFO +4 -4
  2. {pytransit-2.6.8 → pytransit-2.6.9}/PyTransit.egg-info/PKG-INFO +4 -4
  3. {pytransit-2.6.8 → pytransit-2.6.9}/PyTransit.egg-info/SOURCES.txt +0 -1
  4. {pytransit-2.6.8 → pytransit-2.6.9}/README.md +3 -3
  5. {pytransit-2.6.8 → pytransit-2.6.9}/pyproject.toml +2 -2
  6. pytransit-2.6.9/pytransit/__init__.py +93 -0
  7. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/logposteriorfunction.py +20 -15
  8. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/ecintersection.py +87 -4
  9. pytransit-2.6.8/pytransit/__init__.py +0 -101
  10. pytransit-2.6.8/pytransit/version.py +0 -19
  11. {pytransit-2.6.8 → pytransit-2.6.9}/LICENSE +0 -0
  12. {pytransit-2.6.8 → pytransit-2.6.9}/MANIFEST.in +0 -0
  13. {pytransit-2.6.8 → pytransit-2.6.9}/PyTransit.egg-info/dependency_links.txt +0 -0
  14. {pytransit-2.6.8 → pytransit-2.6.9}/PyTransit.egg-info/requires.txt +0 -0
  15. {pytransit-2.6.8 → pytransit-2.6.9}/PyTransit.egg-info/top_level.txt +0 -0
  16. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/__init__.py +0 -0
  17. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/contamination.py +0 -0
  18. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/data/spectra.h5 +0 -0
  19. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/data/transmission.nc +0 -0
  20. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/filter.py +0 -0
  21. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/instrument.py +0 -0
  22. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/contamination/plotting.py +0 -0
  23. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/limb_darkening.py +0 -0
  24. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/__init__.py +0 -0
  25. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/baselines/__init__.py +0 -0
  26. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/baselines/legendrebaseline.py +0 -0
  27. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/baselines/linearbaseline.py +0 -0
  28. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/cntlpf.py +0 -0
  29. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/eclipselpf.py +0 -0
  30. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/__init__.py +0 -0
  31. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/celeriteloglikelihood.py +0 -0
  32. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/clloglikelihood.py +0 -0
  33. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/fmcloglikelihood.py +0 -0
  34. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/logisticloglikelihood.py +0 -0
  35. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/multiceleriteloglikelihood.py +0 -0
  36. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/loglikelihood/wnloglikelihood.py +0 -0
  37. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/lpf.py +0 -0
  38. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/mclpf.py +0 -0
  39. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/mptlpf.py +0 -0
  40. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/ocllpf.py +0 -0
  41. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/ocltdvlpf.py +0 -0
  42. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/oclttvlpf.py +0 -0
  43. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/phasecurvelpf.py +0 -0
  44. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/rvlpf.py +0 -0
  45. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tdvlpf.py +0 -0
  46. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/__init__.py +0 -0
  47. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/ctesslpf.py +0 -0
  48. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/tessttvlpf.py +0 -0
  49. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/tgclpf.py +0 -0
  50. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/tgcmplpf.py +0 -0
  51. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tess/tmpclpf.py +0 -0
  52. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tesslpf.py +0 -0
  53. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/tessoclttvlpf.py +0 -0
  54. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/transitanalysis.py +0 -0
  55. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/transitlpf.py +0 -0
  56. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/lpf/ttvlpf.py +0 -0
  57. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/__init__.py +0 -0
  58. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/eclipse_model.py +0 -0
  59. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/gdmodel.py +0 -0
  60. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/general.py +0 -0
  61. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ldmodel.py +0 -0
  62. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ldtkldm.py +0 -0
  63. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/__init__.py +0 -0
  64. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/general.py +0 -0
  65. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/linear.py +0 -0
  66. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/nonlinear.py +0 -0
  67. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/power_2.py +0 -0
  68. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/quadratic.py +0 -0
  69. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/quadratic_tri.py +0 -0
  70. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/limb_darkening/uniform.py +0 -0
  71. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ma_chromosphere.py +0 -0
  72. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ma_quadratic.py +0 -0
  73. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ma_quadratic_cl.py +0 -0
  74. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ma_uniform.py +0 -0
  75. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/ma_uniform_cl.py +0 -0
  76. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/__init__.py +0 -0
  77. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/gdmodel.py +0 -0
  78. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/general_nb.py +0 -0
  79. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/ldmodels.py +0 -0
  80. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/ldtkldm.py +0 -0
  81. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/ma_chromosphere_nb.py +0 -0
  82. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/ma_quadratic_nb.py +0 -0
  83. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/ma_uniform_nb.py +0 -0
  84. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/phasecurves.py +0 -0
  85. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/qpower2_nb.py +0 -0
  86. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/rrmodel.py +0 -0
  87. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/spmodel.py +0 -0
  88. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/numba/udmodel.py +0 -0
  89. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/opencl/ma_quadratic.cl +0 -0
  90. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/opencl/ma_uniform.cl +0 -0
  91. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/opencl/orbits.cl +0 -0
  92. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/opencl/qpower2.cl +0 -0
  93. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/osmodel.py +0 -0
  94. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/qpower2.py +0 -0
  95. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/qpower2_cl.py +0 -0
  96. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/__init__.py +0 -0
  97. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/common.py +0 -0
  98. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/model.py +0 -0
  99. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/model_full.py +0 -0
  100. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/model_simple.py +0 -0
  101. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/model_trspec.py +0 -0
  102. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/opmodel.py +0 -0
  103. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/opmodel_full.py +0 -0
  104. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/rrmodel.cl +0 -0
  105. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/rrmodel.py +0 -0
  106. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/rrmodel_cl.py +0 -0
  107. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/roadrunner/tsmodel.py +0 -0
  108. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/transitmodel.py +0 -0
  109. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/models/uniform.py +0 -0
  110. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/orbits/__init__.py +0 -0
  111. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/orbits/orbits.py +0 -0
  112. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/orbits/orbits_py.py +0 -0
  113. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/orbits/taylor_z.py +0 -0
  114. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/param/__init__.py +0 -0
  115. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/param/parameter.py +0 -0
  116. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/param/prior.py +0 -0
  117. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/param/utilities.py +0 -0
  118. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/stars/__init__.py +0 -0
  119. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/stars/btsettl.py +0 -0
  120. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/stars/data/avg_bt_settl.fits +0 -0
  121. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/stars/data/avg_husser2013.fits +0 -0
  122. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/stars/husser2013.py +0 -0
  123. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/__init__.py +0 -0
  124. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/astrometry.py +0 -0
  125. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/constants.py +0 -0
  126. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/de.py +0 -0
  127. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/downsample.py +0 -0
  128. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/eclipses.py +0 -0
  129. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/io/__init__.py +0 -0
  130. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/io/lightcurvedata.py +0 -0
  131. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/keplerlc.py +0 -0
  132. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/mdwarfs.py +0 -0
  133. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/misc.py +0 -0
  134. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/mocklc.py +0 -0
  135. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/octasphere.py +0 -0
  136. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/phasecurves.py +0 -0
  137. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/physics.py +0 -0
  138. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/rv.py +0 -0
  139. {pytransit-2.6.8 → pytransit-2.6.9}/pytransit/utils/tess.py +0 -0
  140. {pytransit-2.6.8 → pytransit-2.6.9}/requirements.txt +0 -0
  141. {pytransit-2.6.8 → pytransit-2.6.9}/setup.cfg +0 -0
  142. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_contamination.py +0 -0
  143. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_ma_quadratic.py +0 -0
  144. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_ma_quadratic_nb.py +0 -0
  145. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_qpower2_nb.py +0 -0
  146. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_uniform_model.py +0 -0
  147. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_uniform_model_nb.py +0 -0
  148. {pytransit-2.6.8 → pytransit-2.6.9}/tests/test_z.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyTransit
3
- Version: 2.6.8
3
+ Version: 2.6.9
4
4
  Summary: Fast and painless exoplanet transit light curve modelling.
5
5
  Author-email: Hannu Parviainen <hpparvi@gmail.com>
6
6
  License: GPLv2
@@ -89,11 +89,11 @@ tm.evaluate(k=[[0.10, 0.12], [0.11, 0.13]], ldc=[[0.2, 0.1], [0.5, 0.1],[0.4, 0.
89
89
  RoadRunner [(Parviainen, 2020a)](https://ui.adsabs.harvard.edu/abs/2020MNRAS.499.1633P/abstract) is a fast exoplanet transit model that can use any radially symmetric function to model stellar limb darkening
90
90
  while still being faster to evaluate than the analytical transit model for quadratic limb darkening.
91
91
 
92
- - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_1.ipynb)
92
+ - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_1.ipynb)
93
93
  shows how to use RoadRunner with the included limb darkening models.
94
- - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_2.ipynb)
94
+ - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_2.ipynb)
95
95
  shows how to use RoadRunner with your own limb darkening model.
96
- - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_3.ipynb)
96
+ - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_3.ipynb)
97
97
  shows how to use an LDTk-based limb darkening model LDTkM with RoadRunner.
98
98
 
99
99
  ### Transmission spectroscopy transit model
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyTransit
3
- Version: 2.6.8
3
+ Version: 2.6.9
4
4
  Summary: Fast and painless exoplanet transit light curve modelling.
5
5
  Author-email: Hannu Parviainen <hpparvi@gmail.com>
6
6
  License: GPLv2
@@ -89,11 +89,11 @@ tm.evaluate(k=[[0.10, 0.12], [0.11, 0.13]], ldc=[[0.2, 0.1], [0.5, 0.1],[0.4, 0.
89
89
  RoadRunner [(Parviainen, 2020a)](https://ui.adsabs.harvard.edu/abs/2020MNRAS.499.1633P/abstract) is a fast exoplanet transit model that can use any radially symmetric function to model stellar limb darkening
90
90
  while still being faster to evaluate than the analytical transit model for quadratic limb darkening.
91
91
 
92
- - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_1.ipynb)
92
+ - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_1.ipynb)
93
93
  shows how to use RoadRunner with the included limb darkening models.
94
- - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_2.ipynb)
94
+ - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_2.ipynb)
95
95
  shows how to use RoadRunner with your own limb darkening model.
96
- - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_3.ipynb)
96
+ - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_3.ipynb)
97
97
  shows how to use an LDTk-based limb darkening model LDTkM with RoadRunner.
98
98
 
99
99
  ### Transmission spectroscopy transit model
@@ -10,7 +10,6 @@ PyTransit.egg-info/requires.txt
10
10
  PyTransit.egg-info/top_level.txt
11
11
  pytransit/__init__.py
12
12
  pytransit/limb_darkening.py
13
- pytransit/version.py
14
13
  pytransit/contamination/__init__.py
15
14
  pytransit/contamination/contamination.py
16
15
  pytransit/contamination/filter.py
@@ -48,11 +48,11 @@ tm.evaluate(k=[[0.10, 0.12], [0.11, 0.13]], ldc=[[0.2, 0.1], [0.5, 0.1],[0.4, 0.
48
48
  RoadRunner [(Parviainen, 2020a)](https://ui.adsabs.harvard.edu/abs/2020MNRAS.499.1633P/abstract) is a fast exoplanet transit model that can use any radially symmetric function to model stellar limb darkening
49
49
  while still being faster to evaluate than the analytical transit model for quadratic limb darkening.
50
50
 
51
- - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_1.ipynb)
51
+ - [RRModel example 1](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_1.ipynb)
52
52
  shows how to use RoadRunner with the included limb darkening models.
53
- - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_2.ipynb)
53
+ - [RRModel example 2](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_2.ipynb)
54
54
  shows how to use RoadRunner with your own limb darkening model.
55
- - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/master/notebooks/roadrunner/roadrunner_model_example_3.ipynb)
55
+ - [RRModel example 3](https://github.com/hpparvi/PyTransit/blob/dev/doc/source/notebooks/models/roadrunner/roadrunner_model_example_3.ipynb)
56
56
  shows how to use an LDTk-based limb darkening model LDTkM with RoadRunner.
57
57
 
58
58
  ### Transmission spectroscopy transit model
@@ -4,7 +4,6 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "PyTransit"
7
- version = "2.6.8"
8
7
  description = 'Fast and painless exoplanet transit light curve modelling.'
9
8
  authors=[{name='Hannu Parviainen', email='hpparvi@gmail.com'}]
10
9
  classifiers=[
@@ -21,13 +20,14 @@ keywords = ['astronomy', 'astrophysics', 'exoplanets']
21
20
  requires-python = ">= 3.8"
22
21
  readme = "README.md"
23
22
  license = {text = "GPLv2"}
24
- dynamic = ["dependencies"]
23
+ dynamic = ["version", "dependencies"]
25
24
 
26
25
  [project.urls]
27
26
  homepage = 'https://github.com/hpparvi/PyTransit'
28
27
 
29
28
  [tool.setuptools.dynamic]
30
29
  dependencies = {file = ["requirements.txt"]}
30
+ version = {attr = "pytransit.__version__"}
31
31
 
32
32
  [tool.setuptools]
33
33
  include-package-data = true
@@ -0,0 +1,93 @@
1
+ # PyTransit: fast and easy exoplanet transit modelling in Python.
2
+ # Copyright (C) 2010-2020 Hannu Parviainen
3
+ #
4
+ # This program is free software: you can redistribute it and/or modify
5
+ # it under the terms of the GNU General Public License as published by
6
+ # the Free Software Foundation, either version 3 of the License, or
7
+ # (at your option) any later version.
8
+ #
9
+ # This program is distributed in the hope that it will be useful,
10
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
11
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
+ # GNU General Public License for more details.
13
+ #
14
+ # You should have received a copy of the GNU General Public License
15
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
16
+ #
17
+ # This program is free software: you can redistribute it and/or modify
18
+ # it under the terms of the GNU General Public License as published by
19
+ # the Free Software Foundation, either version 3 of the License, or
20
+ # (at your option) any later version.
21
+ #
22
+ # This program is distributed in the hope that it will be useful,
23
+ # but WITHOUT ANY WARRANTY; without even the implied warranty of
24
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25
+ # GNU General Public License for more details.
26
+ #
27
+ # You should have received a copy of the GNU General Public License
28
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
29
+
30
+
31
+ """PyTransit: fast and easy exoplanet transit modelling in Python
32
+
33
+ This package offers Python interfaces for a set of exoplanet transit light curve
34
+ models implemented in Python (with Numba acceleration) and OpenCL.
35
+
36
+ Author
37
+ Hannu Parviainen <hannu@iac.es>
38
+
39
+ Date
40
+ 06.08.2024
41
+
42
+ """
43
+
44
+ __version__ = '2.6.9'
45
+
46
+ # Generic
47
+ # -------
48
+ from .models.transitmodel import TransitModel
49
+ from .contamination.filter import DeltaFilter, BoxcarFilter, TabulatedFilter, sdss_g, sdss_r, sdss_i, sdss_z
50
+
51
+ # Numba models
52
+ # ------------
53
+ from .models.qpower2 import QPower2Model
54
+ from .models.ma_quadratic import QuadraticModel
55
+ from .models.ma_uniform import UniformModel
56
+ from .models.eclipse_model import EclipseModel
57
+ from .models.ma_chromosphere import ChromosphereModel
58
+ from .models.general import GeneralModel
59
+ from .models.osmodel import OblateStarModel
60
+ from .models.gdmodel import GravityDarkenedModel
61
+
62
+ from .models import RoadRunnerModel, OblatePlanetModel, TransmissionSpectroscopyModel
63
+
64
+ TSModel = TransmissionSpectroscopyModel
65
+ OPModel = OblatePlanetModel
66
+ RRModel = RoadRunnerModel
67
+
68
+ # OpenCL models
69
+ # -------------
70
+ from .models.qpower2_cl import QPower2ModelCL
71
+ from .models.ma_quadratic_cl import QuadraticModelCL
72
+ from .models.ma_uniform_cl import UniformModelCL
73
+
74
+ # LDTk limb darkening for the Swift model
75
+ # ---------------------------------------
76
+
77
+ from .models.ldtkldm import LDTkLDModel #, LDTkLD
78
+ from .models.ldtkldm import LDTkLD
79
+
80
+ # Log posterior functions
81
+ # -----------------------
82
+ from .lpf.lpf import BaseLPF
83
+ from .lpf.transitlpf import TransitLPF
84
+ from .lpf.cntlpf import PhysContLPF
85
+ from .lpf.baselines.legendrebaseline import LegendreBaseline
86
+ from .lpf.baselines.linearbaseline import LinearModelBaseline
87
+ from .lpf.transitanalysis import TransitAnalysis
88
+
89
+ # Utilities
90
+ # ---------
91
+ from .param.parameter import UniformPrior, NormalPrior
92
+ from .utils import md_rs_from_rho
93
+ from .utils.mocklc import create_mock_light_curve
@@ -136,11 +136,12 @@ class LogPosteriorFunction:
136
136
 
137
137
  def optimize_global(self, niter=200, npop=50, population=None, pool=None, lnpost=None, vectorize=True,
138
138
  label='Global optimisation', leave=False, plot_convergence: bool = True, use_tqdm: bool = True,
139
- plot_parameters: tuple = (0, 2, 3, 4)):
139
+ plot_parameters: tuple = (0, 2, 3, 4), min_ptp: float = 1e-2):
140
140
 
141
141
  lnpost = lnpost or self.lnposterior
142
142
  if self.de is None:
143
- self.de = DiffEvol(lnpost, clip(self.ps.bounds, -1, 1), npop, maximize=True, vectorize=vectorize, pool=pool)
143
+ self.de = DiffEvol(lnpost, clip(self.ps.bounds, -1, 1), npop, maximize=True, vectorize=vectorize,
144
+ pool=pool, min_ptp=min_ptp)
144
145
  if population is None:
145
146
  self.de._population[:, :] = self.create_pv_population(npop)
146
147
  else:
@@ -179,24 +180,28 @@ class LogPosteriorFunction:
179
180
  raise ValueError('The MCMC sampler is set to save the results, but the result directory is not set.')
180
181
 
181
182
  lnpost = lnpost or self.lnposterior
182
- if self.sampler is None:
183
- if population is not None:
184
- pop0 = population
185
- elif hasattr(self, '_local_minimization') and self._local_minimization is not None:
186
- pop0 = multivariate_normal(self._local_minimization.x, diag(full(len(self.ps), 0.001 ** 2)), size=npop)
187
- elif self.de is not None:
188
- pop0 = self.de.population.copy()
183
+ if population is not None:
184
+ pop0 = population
185
+ else:
186
+ if self.sampler is None:
187
+ if hasattr(self, '_local_minimization') and self._local_minimization is not None:
188
+ pop0 = multivariate_normal(self._local_minimization.x, diag(full(len(self.ps), 0.001 ** 2)), size=npop)
189
+ elif self.de is not None:
190
+ pop0 = self.de.population.copy()
191
+ else:
192
+ raise ValueError('Sample MCMC needs an initial population.')
189
193
  else:
190
- raise ValueError('Sample MCMC needs an initial population.')
194
+ pop0 = self.sampler.chain[:, -1, :].copy()
195
+
196
+ if self.sampler is None:
191
197
  self.sampler = EnsembleSampler(pop0.shape[0], pop0.shape[1], lnpost, vectorize=vectorize, pool=pool)
192
- else:
193
- pop0 = self.sampler.chain[:, -1, :].copy()
194
198
 
195
199
  for i in tqdm(range(repeats), desc=label, disable=(not use_tqdm), leave=leave):
196
- if reset or i > 0:
200
+ if (self.sampler is not None and reset) or i > 0:
197
201
  self.sampler.reset()
198
- for _ in tqdm(self.sampler.sample(pop0, iterations=niter, thin=thin), total=niter,
199
- desc='Run {:d}/{:d}'.format(i + 1, repeats), leave=False, disable=(not use_tqdm)):
202
+ for _ in tqdm(self.sampler.sample(pop0, iterations=niter, thin=thin, skip_initial_state_check=False),
203
+ total=niter, desc='Run {:d}/{:d}'.format(i + 1, repeats), leave=False,
204
+ disable=(not use_tqdm)):
200
205
  pass
201
206
  if save:
202
207
  self.save(self.result_dir)
@@ -4,9 +4,93 @@ from numpy import ndarray, fabs, pi, full, arange
4
4
  from numba import njit
5
5
 
6
6
  @njit
7
- def create_ellipse(ny: int, k: float, f: float, a: float) -> (ndarray, ndarray):
7
+ def rotated_ellipse_bbox(a: float, f: float):
8
+ """
9
+ Parameters
10
+ ----------
11
+ a : float
12
+ The angle (in radians) by which the ellipse is rotated.
13
+ f : float
14
+ The eccentricity of the ellipse, with a value between 0 and 1.
15
+
16
+ Returns
17
+ -------
18
+ hw : float
19
+ The half-width of the bounding box of the rotated ellipse.
20
+ hh : float
21
+ The half-height of the bounding box of the rotated ellipse.
22
+
23
+ """
24
+ r1, r2 = 1.0, 1.0-f
25
+ ux = r1 * cos(a)
26
+ uy = r1 * sin(a)
27
+ vx = r2 * cos(a + pi/2)
28
+ vy = r2 * sin(a + pi/2)
29
+ hw = sqrt(ux*ux + vx*vx)
30
+ hh = sqrt(uy*uy + vy*vy)
31
+ return hw, hh
32
+
33
+ @njit
34
+ def rotated_ellipse_x(y: float, a: float, f: float) -> tuple[float, float]:
35
+ """Calculate the x coordinates for a rotated ellipse given the y coordinate and the flattening factor.
36
+
37
+ Parameters
38
+ ----------
39
+ y
40
+ The y-coordinate of the point on the ellipse.
41
+ a
42
+ The angle (in radians) of rotation for the ellipse.
43
+ f
44
+ The flattening parameter of the ellipse.
45
+
46
+ Returns
47
+ -------
48
+ tuple[float, float]
49
+ The ellipse x-coordinates for the given y coordinate.
50
+ """
51
+ ca, sa = cos(a), sin(a)
52
+ b = 1.0 - f
53
+ d = b**2*ca**2 - y**2*sa**4 - 2*y**2*sa**2*ca**2 - y**2*ca**4 + sa**2
54
+ if d >= 0.0:
55
+ xl = (y*(-sa*ca + sa*ca/b**2) - sqrt(d)/b) / (ca**2 + sa**2/b**2)
56
+ xr = (y*(-sa*ca + sa*ca/b**2) + sqrt(d)/b) / (ca**2 + sa**2/b**2)
57
+ return xl, xr
58
+ else:
59
+ return nan, nan
60
+
61
+
62
+ @njit
63
+ def rotated_ellipse_dxdy(y: float, a: float, f: float) -> tuple[float, float]:
64
+ """Calculate dx/dy for a rotated ellipse given the y coordinate and the flattening factor.
65
+
66
+ Parameters
67
+ ----------
68
+ y
69
+ The y-coordinate of the point on the ellipse.
70
+ a
71
+ The angle, in radians, of rotation of the ellipse.
72
+ f
73
+ The flattening parameter of the ellipse.
74
+
75
+ Returns
76
+ -------
77
+ tuple[float, float]
78
+ The ellipse derivatives (dx/dy) for the given y coordinate.
8
79
  """
9
- Create the coordinates for a rotated ellipse.
80
+ ca, sa = cos(a), sin(a)
81
+ b = 1.0 - f
82
+ d = b**2*ca**2 - y**2*sa**4 - 2*y**2*sa**2*ca**2 - y**2*ca**4 + sa**2
83
+ if d >= 0.0:
84
+ dxl = (-sa*ca - (-y*sa**4 - 2*y*sa**2*ca**2 - y*ca**4)/(b*sqrt(d)) + sa*ca/b**2)/(ca**2 + sa**2/b**2)
85
+ dxr = (-sa*ca + (-y*sa**4 - 2*y*sa**2*ca**2 - y*ca**4)/(b*sqrt(d)) + sa*ca/b**2)/(ca**2 + sa**2/b**2)
86
+ return dxl, dxr
87
+ else:
88
+ return nan, nan
89
+
90
+
91
+ @njit
92
+ def create_ellipse(ny: int, k: float, f: float, a: float) -> (ndarray, ndarray):
93
+ """Create the coordinates for a rotated ellipse.
10
94
 
11
95
  Parameters
12
96
  ----------
@@ -54,8 +138,7 @@ def create_ellipse(ny: int, k: float, f: float, a: float) -> (ndarray, ndarray):
54
138
 
55
139
  @njit
56
140
  def ellipse_circle_intersection_area(cx: float, cy: float, z: float, k: float, f: float, xs: ndarray, ys: ndarray) -> float:
57
- """
58
- Calculate the intersection area between a rotated ellipse and a circle using a scanline fill approach.
141
+ """Calculate the intersection area between a rotated ellipse and a circle using a scanline fill approach.
59
142
 
60
143
  Parameters
61
144
  ----------
@@ -1,101 +0,0 @@
1
- # PyTransit: fast and easy exoplanet transit modelling in Python.
2
- # Copyright (C) 2010-2020 Hannu Parviainen
3
- #
4
- # This program is free software: you can redistribute it and/or modify
5
- # it under the terms of the GNU General Public License as published by
6
- # the Free Software Foundation, either version 3 of the License, or
7
- # (at your option) any later version.
8
- #
9
- # This program is distributed in the hope that it will be useful,
10
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
11
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
- # GNU General Public License for more details.
13
- #
14
- # You should have received a copy of the GNU General Public License
15
- # along with this program. If not, see <https://www.gnu.org/licenses/>.
16
- #
17
- # This program is free software: you can redistribute it and/or modify
18
- # it under the terms of the GNU General Public License as published by
19
- # the Free Software Foundation, either version 3 of the License, or
20
- # (at your option) any later version.
21
- #
22
- # This program is distributed in the hope that it will be useful,
23
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
24
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25
- # GNU General Public License for more details.
26
- #
27
- # You should have received a copy of the GNU General Public License
28
- # along with this program. If not, see <https://www.gnu.org/licenses/>.
29
-
30
-
31
- """PyTransit: fast and easy exoplanet transit modelling in Python
32
-
33
- This package offers Python interfaces for a set of exoplanet transit light curve
34
- models implemented in Python (with Numba acceleration) and OpenCL.
35
-
36
- Author
37
- Hannu Parviainen <hannu@iac.es>
38
-
39
- Date
40
- 31.01.2024
41
-
42
- """
43
-
44
- import warnings
45
- from numba import NumbaDeprecationWarning
46
-
47
- #TODO: Find where we're using generated_jit and fix it...
48
-
49
- with warnings.catch_warnings():
50
- warnings.simplefilter('ignore', NumbaDeprecationWarning)
51
-
52
- from .version import __version__
53
-
54
- # Generic
55
- # -------
56
- from .models.transitmodel import TransitModel
57
- from .contamination.filter import DeltaFilter, BoxcarFilter, TabulatedFilter, sdss_g, sdss_r, sdss_i, sdss_z
58
-
59
- # Numba models
60
- # ------------
61
- from .models.qpower2 import QPower2Model
62
- from .models.ma_quadratic import QuadraticModel
63
- from .models.ma_uniform import UniformModel
64
- from .models.eclipse_model import EclipseModel
65
- from .models.ma_chromosphere import ChromosphereModel
66
- from .models.general import GeneralModel
67
- from .models.osmodel import OblateStarModel
68
- from .models.gdmodel import GravityDarkenedModel
69
-
70
- from .models import RoadRunnerModel, OblatePlanetModel, TransmissionSpectroscopyModel
71
-
72
- TSModel = TransmissionSpectroscopyModel
73
- OPModel = OblatePlanetModel
74
- RRModel = RoadRunnerModel
75
-
76
- # OpenCL models
77
- # -------------
78
- from .models.qpower2_cl import QPower2ModelCL
79
- from .models.ma_quadratic_cl import QuadraticModelCL
80
- from .models.ma_uniform_cl import UniformModelCL
81
-
82
- # LDTk limb darkening for the Swift model
83
- # ---------------------------------------
84
-
85
- from .models.ldtkldm import LDTkLDModel #, LDTkLD
86
- from .models.ldtkldm import LDTkLD
87
-
88
- # Log posterior functions
89
- # -----------------------
90
- from .lpf.lpf import BaseLPF
91
- from .lpf.transitlpf import TransitLPF
92
- from .lpf.cntlpf import PhysContLPF
93
- from .lpf.baselines.legendrebaseline import LegendreBaseline
94
- from .lpf.baselines.linearbaseline import LinearModelBaseline
95
- from .lpf.transitanalysis import TransitAnalysis
96
-
97
- # Utilities
98
- # ---------
99
- from .param.parameter import UniformPrior, NormalPrior
100
- from .utils import md_rs_from_rho
101
- from .utils.mocklc import create_mock_light_curve
@@ -1,19 +0,0 @@
1
- # PyTransit: fast and easy exoplanet transit modelling in Python.
2
- # Copyright (C) 2010-2019 Hannu Parviainen
3
- #
4
- # This program is free software: you can redistribute it and/or modify
5
- # it under the terms of the GNU General Public License as published by
6
- # the Free Software Foundation, either version 3 of the License, or
7
- # (at your option) any later version.
8
- #
9
- # This program is distributed in the hope that it will be useful,
10
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
11
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
- # GNU General Public License for more details.
13
- #
14
- # You should have received a copy of the GNU General Public License
15
- # along with this program. If not, see <https://www.gnu.org/licenses/>.
16
-
17
- from semantic_version import Version
18
-
19
- __version__ = Version('2.6.8')
File without changes
File without changes
File without changes
File without changes
File without changes