Skip to content

Commit 445c053

Browse files
committed
implement feedback Mireille
1 parent f5d02e2 commit 445c053

File tree

5 files changed

+13
-6
lines changed

5 files changed

+13
-6
lines changed

docs/source/cli.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ This command reads the waveform definitions from the specified `YAML` file, eval
7777
**Arguments:**
7878

7979
* ``YAML``: Path to the input waveform YAML configuration file.
80-
* ``URI``: The URI specifying the IMAS data entry to write to.
80+
* ``URI``: The URI specifying the IMAS data entry or `IMAS NetCDF <https://imas-python.readthedocs.io/en/stable/netcdf.html>`_ filename to write to.
8181

8282
**Options:**
8383

docs/source/training/training.rst

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,15 +119,15 @@ Exercise 1c: Creating a sine wave - part 2
119119

120120
In the previous execise, you might have noticed that there a multiple ways in which you can define the same
121121
waveform. Recreate the waveform of previous exercise using only the following tendency parameters:
122-
``type``, ``start``, ``duration``, ``period``, ``min``, and ``max``.
122+
``type``, ``duration``, ``period``, ``min``, and ``max``.
123123

124124
.. md-tab-item:: Solution
125125

126126
The resulting waveform should be:
127127

128128
.. code-block:: yaml
129129
130-
- {type: sine, start: 10, duration: 5, period: 2, min: 0, max: 6}
130+
- {type: sine, duration: 5, period: 2, min: 0, max: 6}
131131
132132
133133
Exercise 1d: Creating a sine wave - part 3
@@ -591,6 +591,12 @@ Exercise 5c: Exporting from the CLI
591591
592592
This exports the same IDS as in previous exercise.
593593

594+
.. note:: You can also supply the path of a NetCDF file to export to an `IMAS NetCDF <https://imas-python.readthedocs.io/en/stable/netcdf.html>`_ file. For example:
595+
596+
.. code-block:: text
597+
598+
waveform-editor export-ids example.yaml output.nc --linspace 0,800,20
599+
594600
.. _shape_editor_training:
595601

596602
Plasma Shape Editor

waveform_editor/cli.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def export_ids(yaml, uri, csv, linspace):
107107
\b
108108
Arguments:
109109
yaml: Path to the waveform YAML file.
110-
uri: URI of the output Data Entry.
110+
uri: URI of the output Data Entry or file path of output NetCDF file.
111111
\b
112112
Options:
113113
csv: CSV file containing a custom time array.

waveform_editor/gui/io/file_exporter.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def __init__(self, manager):
121121
def _export_type_placeholder(self):
122122
"""Output path placeholder, based on the selected export type."""
123123
return {
124-
IDS_EXPORT: "e.g. imas:hdf5?path=testdb",
124+
IDS_EXPORT: "e.g. imas:hdf5?path=testdb or test.nc",
125125
PNG_EXPORT: "e.g. /path/to/export/pngs",
126126
CSV_EXPORT: "e.g. /path/to/export/output.csv",
127127
PCSSP_EXPORT: "e.g. /path/to/export/output.xml",
@@ -131,7 +131,7 @@ def _export_type_placeholder(self):
131131
def _export_type_description(self):
132132
"""Help description for the selected export type."""
133133
return {
134-
IDS_EXPORT: "Please enter the output IMAS URI below:",
134+
IDS_EXPORT: "Please enter the output IMAS URI or NetCDF file name below:",
135135
PNG_EXPORT: "Please enter an output folder below:",
136136
CSV_EXPORT: "Please enter an output file below:",
137137
PCSSP_EXPORT: "Please enter an output file below:",

waveform_editor/gui/selector/rename_modal.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ def __init__(self):
1111

1212
self.label = pn.pane.Markdown("**Enter a new name for the waveform:**")
1313
self.input = pn.widgets.TextInput(placeholder="Enter new name")
14+
self.input.param.watch(self._handle_accept, "enter_pressed")
1415
self.accept_button = pn.widgets.Button(
1516
name="Accept", button_type="primary", on_click=self._handle_accept
1617
)

0 commit comments

Comments
 (0)