AstarVienna / ScopeSim_Templates

GNU General Public License v3.0
2 stars 4 forks source link

Installation through pip fails #10

Closed hugobuddel closed 4 years ago

hugobuddel commented 4 years ago
$ conda create -n scopesimtemplatetest2 python==3.7
$ conda activate scopesimtemplatetest2
$ pip install git+https://github.com/astronomyk/ScopeSim_Templates.git                                                                                                                                                 
Successfully installed ScopeSim-Templates-0.2 anisocado-0.2 astropy-4.0.1.post1 beautifulsoup4-4.9.1 chardet-3.0.4 cycler-0.10.0 idna-2.10 kiwisolver-1.2.0 matplotlib-3.2.2 numpy-1.19.0 pyckles-0.1.3 pyparsing-2.4.7
 python-dateutil-2.8.1 pyyaml-5.3.1 requests-2.24.0 scipy-1.5.1 scopesim-0.0.6 six-1.15.0 skycalc-ipy-0.1.1.dev0 soupsieve-2.0.1 synphot-0.3 urllib3-1.25.9
$ python
>>> import scopesim_templates
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/__init__.py", line 1, in <module>
    from . import basic
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/basic/__init__.py", line 1, in <module>
    from . import stars
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/basic/stars.py", line 8, in <module>
    from ..utils import stars_utils as su
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/utils/__init__.py", line 2, in <module>
    from . import cluster_utils
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/utils/cluster_utils.py", line 10, in <module>
    MAMAJEK = ascii.read(os.path.join(DIRNAME, "mamajek_alt.dat"), delimiter="|")
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/astropy/io/ascii/ui.py", line 287, in read
    dat = _guess(table, new_kwargs, format, fast_reader)
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/astropy/io/ascii/ui.py", line 447, in _guess
    dat = reader.read(table)
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/astropy/io/ascii/core.py", line 1165, in read
    self.lines = self.inputter.get_lines(table)
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/astropy/io/ascii/core.py", line 305, in get_lines
    encoding=self.encoding) as fileobj:
  File "../envs/scopesimtemplatetest2/lib/python3.7/contextlib.py", line 112, in __enter__
    return next(self.gen)
  File "../envs/scopesimtemplatetest2/lib/python3.7/site-packages/astropy/utils/data.py", line 237, in get_readable_fileobj
    fileobj = io.FileIO(name_or_obj, 'r')
FileNotFoundError: [Errno 2] No such file or directory: '../envs/scopesimtemplatetest2/lib/python3.7/site-packages/scopesim_templates/utils/mamajek_alt.dat'

Edit: forgot pip install git+https://github.com/astronomyk/ScopeSim_Templates.git

hugobuddel commented 4 years ago

Seems to work now!