Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Simon Perkins
ducc
Commits
1164fa5a
Commit
1164fa5a
authored
Jun 03, 2020
by
Martin Reinecke
Browse files
more renaming
parent
24cef791
Changes
2
Hide whitespace changes
Inline
Side-by-side
pyinterpol_ng/demo.py
View file @
1164fa5a
import
pyinterpol_ng
import
ducc_0_1.pyinterpol_ng
as
pyinterpol_ng
import
numpy
as
np
import
time
...
...
@@ -28,15 +28,6 @@ def myalmdot(a1,a2,lmax,mmax,spin):
return
np
.
vdot
(
compress_alm
(
a1
,
lmax
),
compress_alm
(
np
.
conj
(
a2
),
lmax
))
def
convolve
(
alm1
,
alm2
,
lmax
):
job
=
pysharp
.
sharpjob_d
()
job
.
set_triangular_alm_info
(
lmax
,
lmax
)
job
.
set_gauss_geometry
(
lmax
+
1
,
2
*
lmax
+
1
)
map
=
job
.
alm2map
(
alm1
)
*
job
.
alm2map
(
alm2
)
job
.
set_triangular_alm_info
(
0
,
0
)
return
job
.
map2alm
(
map
)[
0
]
*
np
.
sqrt
(
4
*
np
.
pi
)
lmax
=
1024
kmax
=
13
ncomp
=
1
...
...
pyinterpol_ng/test/test_interpol_ng.py
View file @
1164fa5a
...
...
@@ -2,7 +2,7 @@ import numpy as np
import
pytest
from
numpy.testing
import
assert_
import
ducc_0_1.pyinterpol_ng
as
pyinterpol_ng
import
ducc_0_1.
pysharp
as
pysharp
import
ducc_0_1.
sht
as
sht
pmp
=
pytest
.
mark
.
parametrize
...
...
@@ -31,7 +31,7 @@ def random_alm(lmax, mmax, ncomp):
def
convolve
(
alm1
,
alm2
,
lmax
):
job
=
pysharp
.
sharpjob_d
()
job
=
sht
.
sharpjob_d
()
job
.
set_triangular_alm_info
(
lmax
,
lmax
)
job
.
set_gauss_geometry
(
lmax
+
1
,
2
*
lmax
+
1
)
map
=
job
.
alm2map
(
alm1
)
*
job
.
alm2map
(
alm2
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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