Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gregory Ashton
PyFstat
Commits
b9f85d41
Commit
b9f85d41
authored
May 04, 2017
by
Gregory Ashton
Browse files
Alert user (without failing) if astropy is not installed
parent
adfec1d1
Changes
1
Hide whitespace changes
Inline
Side-by-side
pyfstat/injection_helper_functions.py
View file @
b9f85d41
...
...
@@ -4,9 +4,13 @@
"""
import
numpy
as
np
from
astropy
import
units
as
u
from
astropy.coordinates
import
SkyCoord
from
astropy.time
import
Time
import
logging
try
:
from
astropy
import
units
as
u
from
astropy.coordinates
import
SkyCoord
from
astropy.time
import
Time
except
ImportError
:
logging
.
warning
(
'Python module astropy not installed'
)
# Assume Earth goes around Sun in a non-wobbling circle at constant speed;
# Still take the zero longitude to be the Earth's position during the March
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment