Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
VILLASdataprocessing
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ACS
Public
VILLASframework
VILLASdataprocessing
Commits
1f645174
Commit
1f645174
authored
7 years ago
by
Markus Mirz
Browse files
Options
Downloads
Patches
Plain Diff
added plot example for circuit tests
parent
535c3b82
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
examples/DPsim/examples_plot.py
+27
-0
27 additions, 0 deletions
examples/DPsim/examples_plot.py
examples/DPsim/plot_absolute_example.py
+0
-11
0 additions, 11 deletions
examples/DPsim/plot_absolute_example.py
with
27 additions
and
11 deletions
examples/DPsim/examples_plot.py
0 → 100644
+
27
−
0
View file @
1f645174
from
dataprocessing.dpsim
import
*
from
dataprocessing.plottools
import
*
path
=
'
D:
\\
path
\\
to
\\
logs
\\
'
logName
=
'
simulation_name_LeftVector
'
logFilename
=
path
+
logName
+
'
.csv
'
ts_dpsim
=
read_timeseries_dpsim_cmpl
(
logFilename
)
phasors
=
get_node_voltage_phasors
(
ts_dpsim
)
print
(
'
Print phasors for all nodes at first time step:
'
)
for
node
,
phasor
in
phasors
.
items
():
print
(
node
+
'
:
'
+
str
(
phasor
[
'
abs
'
].
values
[
0
])
+
'
<
'
+
str
(
phasor
[
'
phase
'
].
values
[
0
]))
print
(
'
Print phasors for all nodes at last time step:
'
)
for
node
,
phasor
in
phasors
.
items
():
print
(
node
+
'
:
'
+
str
(
phasor
[
'
abs
'
].
values
[
-
1
])
+
'
<
'
+
str
(
phasor
[
'
phase
'
].
values
[
-
1
]))
emt_voltages
=
get_node_emt_voltages
(
ts_dpsim
,
50
)
print
(
'
Print EMT voltages for all nodes at last time step:
'
)
for
node
,
voltage
in
emt_voltages
.
items
():
print
(
node
+
'
:
'
+
str
(
voltage
.
values
[
-
1
]))
# Change node number to fit example
#plot_timeseries(1, phasors['n2']['abs'])
plot_timeseries
(
2
,
emt_voltages
[
'
n2
'
])
plt
.
show
()
This diff is collapsed.
Click to expand it.
examples/DPsim/plot_absolute_example.py
deleted
100644 → 0
+
0
−
11
View file @
535c3b82
from
dataprocessing.plotdpsim
import
*
path
=
'
C:
\\
Users
\\
mmi
\\
git
\\
PowerSystemSimulation
\\
gre
\\
step-dist-init
\\
'
plot_dpsim_abs
(
path
+
'
lvector-ref.csv
'
,
'
reference
'
,
2
,
path
+
'
lvector0-local_rm-first-row.csv
'
,
'
local
'
,
2
)
plot_dpsim_abs
(
path
+
'
lvector-ref.csv
'
,
'
reference
'
,
2
,
path
+
'
lvector0-netem.csv
'
,
'
netem
'
,
2
)
plot_dpsim_abs
(
path
+
'
lvector-ref.csv
'
,
'
reference
'
,
2
,
path
+
'
lvector0-dist.csv
'
,
'
dist
'
,
2
)
\ No newline at end of file
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