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
csst-sims
csst_ifs_gehong
Commits
87388df4
Commit
87388df4
authored
Apr 15, 2024
by
Feng Shuai
💬
Browse files
Update tests/test_cube3d.py
parent
7b5d51ed
Pipeline
#4100
failed with stage
in 0 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
tests/test_cube3d.py
View file @
87388df4
...
...
@@ -65,12 +65,15 @@ class test_cube3d(unittest.TestCase):
u
.
savefits
(
'result.fits'
)
plt
.
figure
(
figsize
=
(
16
,
4
))
plt
.
plot
(
u
.
wave
,
np
.
log10
(
u
.
flux
[
50
,
50
,:]),
color
=
'blue'
,
label
=
r
'$v=%4.2f$'
%
(
velmap
.
map
[
50
,
50
]))
plt
.
plot
(
u
.
wave
,
np
.
log10
(
u
.
flux
[
5
,
95
,:]),
color
=
'red'
,
label
=
r
'$v=%4.2f$'
%
(
velmap
.
map
[
5
,
95
]))
plt
.
xlim
(
3500
,
9500
)
plt
.
legend
(
frameon
=
False
)
plt
.
savefig
(
'./image/test_cube3d_spec.png'
)
if
np
.
sum
(
u
.
flux
[
50
,
50
,:])
!=
np
.
sum
(
u
.
flux
[
5
,
95
,:]):
print
(
"No Problem!"
)
#plt.figure(figsize=(16,4))
#plt.plot(u.wave,np.log10(u.flux[50,50,:]),color='blue',label=r'$v=%4.2f$'%(velmap.map[50,50]))
#plt.plot(u.wave,np.log10(u.flux[5,95,:]),color='red',label=r'$v=%4.2f$'%(velmap.map[5,95]))
#plt.xlim(3500,9500)
#plt.legend(frameon=False)
#plt.savefig('./image/test_cube3d_spec.png')
print
(
"-----------------------------------------------------------------"
)
print
(
">>> Unit test for **Spec Cube** Modelling has been passed!"
)
...
...
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