Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
gdat
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SPC
gdat
Commits
684cf4fe
Commit
684cf4fe
authored
5 years ago
by
Olivier Sauter
Committed by
Olivier Sauter
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
fix ec_ angles and nbi frac orientation
parent
3e883999
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!23
Small fixes
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
matlab/TCV_IMAS/tcv2ids2database.m
+12
-1
12 additions, 1 deletion
matlab/TCV_IMAS/tcv2ids2database.m
matlab/TCV_IMAS/tcv_get_ids_ec_antennas.m
+2
-2
2 additions, 2 deletions
matlab/TCV_IMAS/tcv_get_ids_ec_antennas.m
matlab/TCV_IMAS/tcv_get_ids_nbi.m
+2
-2
2 additions, 2 deletions
matlab/TCV_IMAS/tcv_get_ids_nbi.m
with
16 additions
and
5 deletions
matlab/TCV_IMAS/tcv2ids2database.m
+
12
−
1
View file @
684cf4fe
...
...
@@ -98,7 +98,18 @@ params_not_in_tcv2ids = {'run_out','occurence','tree_user','tree_tokamak','tree_
params_tcv2ids
=
rmfield
(
params_tcv2ids2database
,
params_not_in_tcv2ids
);
[
ids_from_tcv
,
idsok
]
=
tcv2ids
(
shot
,
params_tcv2ids
);
ids_from_tcv
.
params_tcv2ids2database
=
params_tcv2ids2database
;
ids_from_tcv
.
params_tcv2ids2database
% check that coreprofiles is ok, could mean anaprofs did not succeed
if
isfield
(
ids_from_tcv
,
'core_profiles'
)
if
isempty
(
ids_from_tcv
.
core_profiles
.
time
)
warning
([
char
(
10
)
'*************'
char
(
10
)
...
'core_profiles.time is empty, probably no data in CONF nodes for TCV, check with hldsi(shot) command on SPC-EPFL lacs computers'
...
char
(
10
)
'*************'
char
(
10
)]);
return
end
end
%% can plot with: [plotids_H] = plotids([],idsok.ids{1},idsok.ids{2});
if
isfield
(
ids_from_tcv
,
'tf'
)
% avoid present problem of not saving data if ids_from_tcv.tf.field_map{1}.time is not set
...
...
This diff is collapsed.
Click to expand it.
matlab/TCV_IMAS/tcv_get_ids_ec_antennas.m
+
2
−
2
View file @
684cf4fe
...
...
@@ -74,9 +74,9 @@ for iant=1:nb_antennas
ids_ec_antennas
.
antenna
{
iant
}
.
launching_position
.
r
.
time
(
i
)
=
time_launch
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_position
.
z
.
time
(
i
)
=
time_launch
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_position
.
phi
.
time
(
i
)
=
time_launch
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_pol
.
data
(
i
)
=
launch_params
{
iant
}{
it_ok
{
iant
}(
i
)}
.
theta_toray
*
pi
/
180.
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_pol
.
data
(
i
)
=
(
90.
-
launch_params
{
iant
}{
it_ok
{
iant
}(
i
)}
.
theta_toray
)
*
pi
/
180.
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_pol
.
time
(
i
)
=
time_launch
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_tor
.
data
(
i
)
=
launch_params
{
iant
}{
it_ok
{
iant
}(
i
)}
.
phi_toray
*
pi
/
180.
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_tor
.
data
(
i
)
=
(
180.
-
launch_params
{
iant
}{
it_ok
{
iant
}(
i
)}
.
phi_toray
)
*
pi
/
180.
;
ids_ec_antennas
.
antenna
{
iant
}
.
launching_angle_tor
.
time
(
i
)
=
time_launch
;
ids_ec_antennas
.
antenna
{
iant
}
.
beam
.
spot
.
size
.
data
(
i
,
1
:
2
)
=
0.05
.*
ones
(
size
(
time_launch
));
ids_ec_antennas
.
antenna
{
iant
}
.
beam
.
spot
.
size
.
time
(
i
)
=
time_launch
;
...
...
This diff is collapsed.
Click to expand it.
matlab/TCV_IMAS/tcv_get_ids_nbi.m
+
2
−
2
View file @
684cf4fe
...
...
@@ -75,14 +75,14 @@ for iunit=1:nb_units
ids_nbi
.
unit
{
iunit
}
.
beam_power_fraction
.
time
=
p_frac
.
t
;
ids_nbi_description
.
unit
{
iunit
}
.
beam_power_fraction
=
[
'from \results::'
results_subname
{
iunit
}
':fraction'
];
if
~
isempty
(
p_frac
.
data
)
&&
size
(
p_frac
.
data
,
2
)
>=
3
ids_nbi
.
unit
{
iunit
}
.
beam_power_fraction
.
data
=
p_frac
.
data
(:,
1
:
3
)
*
0.01
;
ids_nbi
.
unit
{
iunit
}
.
beam_power_fraction
.
data
=
p_frac
.
data
(:,
1
:
3
)
'
*
0.01
;
i_frac
=
p_frac
.
data
(:,
1
:
3
)
.*
repmat
([
1
2
3
],
size
(
p_frac
.
data
,
1
),
1
);
% to be compatible with older matlab version .*[1 2 3] not ok
i_frac
=
i_frac
.*
1.
/
repmat
(
sum
(
i_frac
),
size
(
p_frac
.
data
,
1
),
1
);
else
ids_nbi
.
unit
{
iunit
}
.
beam_power_fraction
.
data
=
p_frac
.
data
;
i_frac
=
p_frac
.
data
;
end
ids_nbi
.
unit
{
iunit
}
.
beam_current_fraction
.
data
=
i_frac
;
ids_nbi
.
unit
{
iunit
}
.
beam_current_fraction
.
data
=
i_frac
'
;
ids_nbi
.
unit
{
iunit
}
.
beam_current_fraction
.
time
=
p_frac
.
t
;
%% species
ids_nbi
.
unit
{
iunit
}
.
species
.
a
=
species
.
a
(
iunit
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment