Skip to content

Commit

Permalink
Compatibility with Python 3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomas Stolker committed Dec 19, 2020
1 parent e6165bf commit 3cf6aed
Show file tree
Hide file tree
Showing 20 changed files with 24 additions and 27 deletions.
2 changes: 1 addition & 1 deletion .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build:
image: latest

python:
version: 3.7
version: 3.8
install:
- requirements: requirements.txt
- requirements: docs/requirements.txt
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ dist: xenial
python:
- 3.6
- 3.7
- 3.8

before_install:
- sudo apt-get install pandoc
Expand Down
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
.. image:: https://badge.fury.io/py/species.svg
:target: https://badge.fury.io/py/species

.. image:: https://img.shields.io/badge/Python-3.6%2C%203.7-yellow.svg?style=flat
.. image:: https://img.shields.io/badge/Python-3.6%2C%203.7%2C%203.8-yellow.svg?style=flat
:target: https://pypi.python.org/pypi/species

.. image:: https://travis-ci.org/tomasstolker/species.svg?branch=master
Expand Down Expand Up @@ -37,7 +37,7 @@ Documentation can be found at `http://species.readthedocs.io <http://species.rea
Attribution
-----------

Please cite `Stolker et al. (2020) <https://ui.adsabs.harvard.edu/abs/2020A%26A...635A.182S/abstract>`_ whenever results from *species* are used in a publication. Please also make sure to give credit to the relevant papers regarding the use of the publicly available data that *species* benefits from. The *species* logo is `available <https://people.phys.ethz.ch/~stolkert/species/species_logo.zip>`_ for use in presentations.
Please cite `Stolker et al. (2020) <https://ui.adsabs.harvard.edu/abs/2020A%26A...635A.182S/abstract>`_ whenever results from *species* are used in a publication. Please also make sure to give credit to the relevant papers regarding the use of the publicly available data that *species* benefits from. The *species* logo is `available <https://home.strw.leidenuniv.nl/~stolker/species/species_logo.zip>`_ for use in presentations.

Contributing
------------
Expand Down
4 changes: 2 additions & 2 deletions docs/about.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ About
Questions & feedback
--------------------

*species* is developed by Tomas Stolker (tomas.stolker@phys.ethz.ch). Feel free to send an email for questions, comments, or suggestions.
*species* is developed by Tomas Stolker (stolker@strw.leidenuniv.nl). Feel free to send an email for questions, comments, or suggestions.

Attribution
-----------
Expand All @@ -16,4 +16,4 @@ Please cite `Stolker et al. (2020) <https://ui.adsabs.harvard.edu/abs/2020A%26A.
Logo
----

Are you presenting results obtained with `species` in a talk or poster? Please consider using the `logo <https://people.phys.ethz.ch/~stolkert/species/species_logo.zip>`_ that is available in PDF and PNG format.
Are you presenting results obtained with `species` in a talk or poster? Please consider using the `logo <https://home.strw.leidenuniv.nl/~stolker/species/species_logo.zip>`_ that is available in PDF and PNG format.
4 changes: 2 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
Documentation for *species*
===========================

*species* is a toolkit for atmospheric characterization of self-luminous exoplanets and brown dwarfs. The package has been developed and is maintained by |stolker|.
*species* is a toolkit for atmospheric characterization of directly imaged exoplanets. The package has been developed and is maintained by |stolker|.

.. |stolker| raw:: html

<a href="https://people.phys.ethz.ch/~stolkert/" target="_blank">Tomas Stolker</a>
<a href="https://home.strw.leidenuniv.nl/~stolker/" target="_blank">Tomas Stolker</a>

.. toctree::
:maxdepth: 2
Expand Down
3 changes: 2 additions & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Installation
============

*species* is compatible with Python 3.6/3.7 and is available in the |pypi| and on |github|.
*species* is compatible with Python 3.6/3.7/3.8 and is available in the |pypi| and on |github|.


Installation from PyPI
----------------------
Expand Down
1 change: 0 additions & 1 deletion docs/species.analysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ species.analysis.photometry module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
1 change: 0 additions & 1 deletion docs/species.core.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ species.core.setup module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
1 change: 0 additions & 1 deletion docs/species.data.rst
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,6 @@ species.data.vlm\_plx module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
1 change: 0 additions & 1 deletion docs/species.plot.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ species.plot.plot\_spectrum module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
1 change: 0 additions & 1 deletion docs/species.read.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ species.read.read\_spectrum module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
1 change: 0 additions & 1 deletion docs/species.util.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ species.util.test\_util module
:undoc-members:
:show-inheritance:


Module contents
---------------

Expand Down
7 changes: 4 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
setup(
name='species',
version='0.3.2',
description='Toolkit for atmospheric characterization of exoplanets and brown dwarfs',
description='Toolkit for atmospheric characterization of directly imaged exoplanets',
long_description=open('README.rst').read(),
long_description_content_type='text/x-rst',
author='Tomas Stolker',
author_email='tomas.stolker@phys.ethz.ch',
author_email='stolker@strw.leidenuniv.nl',
url='https://github.com/tomasstolker/species',
project_urls={'Documentation': 'https://species.readthedocs.io'},
packages=['species',
Expand All @@ -25,7 +25,7 @@
'species.plot',
'species.read',
'species.util'],
package_dir={'species':'species'},
package_dir={'species': 'species'},
include_package_data=True,
install_requires=reqs,
license='MIT',
Expand All @@ -39,5 +39,6 @@
'Natural Language :: English',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
],
)
2 changes: 1 addition & 1 deletion species/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,5 +65,5 @@
__license__ = 'MIT'
__version__ = '0.3.2'
__maintainer__ = 'Tomas Stolker'
__email__ = 'tomas.stolker@phys.ethz.ch'
__email__ = 'stolker@strw.leidenuniv.nl'
__status__ = 'Development'
6 changes: 3 additions & 3 deletions species/data/dust.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def add_optical_constants(input_path: str,
if not os.path.exists(input_path):
os.makedirs(input_path)

url = 'https://people.phys.ethz.ch/~stolkert/species/optical_constants.zip'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/optical_constants.zip'

data_file = os.path.join(input_path, 'optical_constants.zip')

Expand Down Expand Up @@ -116,7 +116,7 @@ def add_cross_sections(input_path: str,
if not os.path.exists(input_path):
os.makedirs(input_path)

url = 'https://people.phys.ethz.ch/~stolkert/species/lognorm_mgsio3_c_ext.fits'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/lognorm_mgsio3_c_ext.fits'

data_file = os.path.join(input_path, 'lognorm_mgsio3_c_ext.fits')

Expand Down Expand Up @@ -150,7 +150,7 @@ def add_cross_sections(input_path: str,
data_range = f'{np.amin(hdu_list[3].data)} - {np.amax(hdu_list[3].data)}'
print(f' - Geometric standard deviation range: {data_range}')

url = 'https://people.phys.ethz.ch/~stolkert/species/powerlaw_mgsio3_c_ext.fits'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/powerlaw_mgsio3_c_ext.fits'

data_file = os.path.join(input_path, 'powerlaw_mgsio3_c_ext.fits')

Expand Down
4 changes: 2 additions & 2 deletions species/data/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def download_filter(filter_id: str) -> Tuple[Optional[np.ndarray],
os.remove('VisAO_Ys_filter_curve.dat')

elif filter_id == 'ALMA/band6':
url = 'https://people.phys.ethz.ch/~stolkert/species/alma_band6.dat'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/alma_band6.dat'
urllib.request.urlretrieve(url, 'alma_band6.dat')

wavelength, transmission = np.loadtxt('alma_band6.dat', unpack=True)
Expand All @@ -96,7 +96,7 @@ def download_filter(filter_id: str) -> Tuple[Optional[np.ndarray],
os.remove('alma_band6.dat')

elif filter_id == 'ALMA/band7':
url = 'https://people.phys.ethz.ch/~stolkert/species/alma_band7.dat'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/alma_band7.dat'
urllib.request.urlretrieve(url, 'alma_band7.dat')

wavelength, transmission = np.loadtxt('alma_band7.dat', unpack=True)
Expand Down
2 changes: 1 addition & 1 deletion species/data/irtf.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def add_irtf(input_path: str,
if sptypes is None:
sptypes = ['F', 'G', 'K', 'M', 'L', 'T']

distance_url = 'https://people.phys.ethz.ch/~stolkert/species/distance.dat'
distance_url = 'https://home.strw.leidenuniv.nl/~stolker/species/distance.dat'
distance_file = os.path.join(input_path, 'distance.dat')

if not os.path.isfile(distance_file):
Expand Down
2 changes: 1 addition & 1 deletion species/data/spex.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def add_spex(input_path, database):
None
"""

distance_url = 'https://people.phys.ethz.ch/~stolkert/species/distance.dat'
distance_url = 'https://home.strw.leidenuniv.nl/~stolker/species/distance.dat'
distance_file = os.path.join(input_path, 'distance.dat')

if not os.path.isfile(distance_file):
Expand Down
2 changes: 1 addition & 1 deletion species/plot/plot_spectrum.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ def plot_spectrum(boxes: list,
ax1.set_xlabel('Wavelength (µm)', fontsize=13)

if filters is not None:
ax2.set_ylabel('T$_\lambda$', fontsize=13)
ax2.set_ylabel(r'T$_\lambda$', fontsize=13)

if residuals is not None:
if quantity == 'flux density':
Expand Down
2 changes: 1 addition & 1 deletion test/test_read/test_isochrone.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def setup_class(self):

filename = 'model.AMES-Cond-2000.M-0.0.NaCo.Vega'

url = 'https://people.phys.ethz.ch/~stolkert/species/model.AMES-Cond-2000.M-0.0.NaCo.Vega'
url = 'https://home.strw.leidenuniv.nl/~stolker/species/model.AMES-Cond-2000.M-0.0.NaCo.Vega'

urllib.request.urlretrieve(url, filename)

Expand Down

0 comments on commit 3cf6aed

Please sign in to comment.