Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
L
lalsuite
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
106
Issues
106
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
25
Merge Requests
25
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Test Cases
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lscsoft
lalsuite
Commits
536309b2
Commit
536309b2
authored
Mar 24, 2017
by
Leo Pound Singer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Drop monkeypatch for unsupported version of Matplotlib
Original: 5fb180c7e2e0c73657f0e333f5183fda816d3f23
parent
0bc97412
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
35 deletions
+1
-35
lalinference/python/lalinference/plot/allsky.py
lalinference/python/lalinference/plot/allsky.py
+1
-35
No files found.
lalinference/python/lalinference/plot/allsky.py
View file @
536309b2
...
...
@@ -44,41 +44,7 @@ import numpy as np
if
mpl_version
>=
'1.3.0'
:
FixedMollweideAxes
=
MollweideAxes
elif
mpl_version
<
'1.2.0'
:
class
FixedMollweideAxes
(
MollweideAxes
):
"""Patched version of matplotlib's Mollweide projection that implements a
correct inverse transform."""
class
FixedMollweideTransform
(
MollweideAxes
.
MollweideTransform
):
def
inverted
(
self
):
return
FixedMollweideAxes
.
InvertedFixedMollweideTransform
(
self
.
_resolution
)
inverted
.
__doc__
=
Transform
.
inverted
.
__doc__
class
InvertedFixedMollweideTransform
(
MollweideAxes
.
InvertedMollweideTransform
):
def
inverted
(
self
):
return
FixedMollweideAxes
.
FixedMollweideTransform
(
self
.
_resolution
)
inverted
.
__doc__
=
Transform
.
inverted
.
__doc__
def
transform
(
self
,
xy
):
x
=
xy
[:,
0
:
1
]
y
=
xy
[:,
1
:
2
]
sqrt2
=
np
.
sqrt
(
2
)
sintheta
=
y
/
sqrt2
with
np
.
errstate
(
invalid
=
'ignore'
):
costheta
=
np
.
sqrt
(
1.
-
0.5
*
y
*
y
)
longitude
=
0.25
*
sqrt2
*
np
.
pi
*
x
/
costheta
latitude
=
np
.
arcsin
(
2
/
np
.
pi
*
(
np
.
arcsin
(
sintheta
)
+
sintheta
*
costheta
))
return
np
.
concatenate
((
longitude
,
latitude
),
1
)
transform
.
__doc__
=
Transform
.
transform
.
__doc__
transform_non_affine
=
transform
def
_get_core_transform
(
self
,
resolution
):
return
self
.
FixedMollweideTransform
(
resolution
)
projection_registry
.
register
(
FixedMollweideAxes
)
raise
NotImplemented
(
'This module requires matplotlib >= 1.2.0. You have matplotlib {}.'
.
format
(
mpl_version
))
else
:
class
FixedMollweideAxes
(
MollweideAxes
):
"""Patched version of matplotlib's Mollweide projection that implements a
...
...
Write
Preview
Markdown
is supported
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