From b2dbedfef394ecf197815a14bb1e39d1577c659b Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Tue, 20 Jun 2023 06:56:11 +0000 Subject: automatic import of python-vetting --- .gitignore | 1 + python-vetting.spec | 167 ++++++++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 169 insertions(+) create mode 100644 python-vetting.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore index e69de29..49bccba 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/vetting-0.3.tar.gz diff --git a/python-vetting.spec b/python-vetting.spec new file mode 100644 index 0000000..5f32fbc --- /dev/null +++ b/python-vetting.spec @@ -0,0 +1,167 @@ +%global _empty_manifest_terminate_build 0 +Name: python-vetting +Version: 0.3 +Release: 1 +Summary: Simple, stand-alone vetting tools for transiting signals in Keper, K2 and TESS data +License: MIT +URL: https://github.com/SSDataLab/vetting +Source0: https://mirrors.aliyun.com/pypi/web/packages/7f/2e/5a2f44fd291eed095ff4393f9e9effdd588c87495ee05311f095facfbd07/vetting-0.3.tar.gz +BuildArch: noarch + +Requires: python3-lightkurve +Requires: python3-corner + +%description +# vetting + +**`vetting` contains simple, stand-alone Python tools for vetting transiting signals in NASA's Kepler, K2 and TESS data. `vetting` requires an installation of Python 3.8 or higher.** + +[![pypi](https://img.shields.io/pypi/v/vetting)](https://pypi.org/project/vetting/) +![pytest](https://github.com/ssdatalab/vetting/workflows/pytest/badge.svg) + +## Installation + +You can install `vetting` by executing the following in a terminal + +``` +pip install vetting +``` + +### Centroid testing + +An example of a simple test is shown below. + +![Example of simple centroid test](https://github.com/SSDataLab/vetting/raw/main/demo.png) + +Here a significant offset is detected in the centroid of false positive KOI-608 during transit. The p-value for the points during transit being drawn from the same distribution as the points out of transit is low, (there is a less than 1% chance these are drawn from the same distribution). To recreate this example you can use the following script: + +```python +import lightkurve as lk +from vetting import centroid_test + +tpf = lk.search_targetpixelfile('KOI-608', mission='Kepler', quarter=10).download() +period, t0, dur = 25.3368592, 192.91552, 8.85/24 +r = centroid_test(tpf, period, t0, dur, aperture_mask='pipeline', plot=False) +``` + + +%package -n python3-vetting +Summary: Simple, stand-alone vetting tools for transiting signals in Keper, K2 and TESS data +Provides: python-vetting +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-vetting +# vetting + +**`vetting` contains simple, stand-alone Python tools for vetting transiting signals in NASA's Kepler, K2 and TESS data. `vetting` requires an installation of Python 3.8 or higher.** + +[![pypi](https://img.shields.io/pypi/v/vetting)](https://pypi.org/project/vetting/) +![pytest](https://github.com/ssdatalab/vetting/workflows/pytest/badge.svg) + +## Installation + +You can install `vetting` by executing the following in a terminal + +``` +pip install vetting +``` + +### Centroid testing + +An example of a simple test is shown below. + +![Example of simple centroid test](https://github.com/SSDataLab/vetting/raw/main/demo.png) + +Here a significant offset is detected in the centroid of false positive KOI-608 during transit. The p-value for the points during transit being drawn from the same distribution as the points out of transit is low, (there is a less than 1% chance these are drawn from the same distribution). To recreate this example you can use the following script: + +```python +import lightkurve as lk +from vetting import centroid_test + +tpf = lk.search_targetpixelfile('KOI-608', mission='Kepler', quarter=10).download() +period, t0, dur = 25.3368592, 192.91552, 8.85/24 +r = centroid_test(tpf, period, t0, dur, aperture_mask='pipeline', plot=False) +``` + + +%package help +Summary: Development documents and examples for vetting +Provides: python3-vetting-doc +%description help +# vetting + +**`vetting` contains simple, stand-alone Python tools for vetting transiting signals in NASA's Kepler, K2 and TESS data. `vetting` requires an installation of Python 3.8 or higher.** + +[![pypi](https://img.shields.io/pypi/v/vetting)](https://pypi.org/project/vetting/) +![pytest](https://github.com/ssdatalab/vetting/workflows/pytest/badge.svg) + +## Installation + +You can install `vetting` by executing the following in a terminal + +``` +pip install vetting +``` + +### Centroid testing + +An example of a simple test is shown below. + +![Example of simple centroid test](https://github.com/SSDataLab/vetting/raw/main/demo.png) + +Here a significant offset is detected in the centroid of false positive KOI-608 during transit. The p-value for the points during transit being drawn from the same distribution as the points out of transit is low, (there is a less than 1% chance these are drawn from the same distribution). To recreate this example you can use the following script: + +```python +import lightkurve as lk +from vetting import centroid_test + +tpf = lk.search_targetpixelfile('KOI-608', mission='Kepler', quarter=10).download() +period, t0, dur = 25.3368592, 192.91552, 8.85/24 +r = centroid_test(tpf, period, t0, dur, aperture_mask='pipeline', plot=False) +``` + + +%prep +%autosetup -n vetting-0.3 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "\"/%h/%f\"\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "\"/%h/%f\"\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "\"/%h/%f\"\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "\"/%h/%f\"\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "\"/%h/%f.gz\"\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-vetting -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Tue Jun 20 2023 Python_Bot - 0.3-1 +- Package Spec generated diff --git a/sources b/sources new file mode 100644 index 0000000..f6d075b --- /dev/null +++ b/sources @@ -0,0 +1 @@ +9862c32e910a5e8ed23078d64675248a vetting-0.3.tar.gz -- cgit v1.2.3