Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/DeDop/dedop-core
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-ep committed Nov 20, 2017
2 parents ff8a2fd + a9fd51d commit 5a68346
Show file tree
Hide file tree
Showing 9 changed files with 99 additions and 73 deletions.
2 changes: 1 addition & 1 deletion .github/issue_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

### Actual behavior

*Describe here what you expected DeDop to do.*
*Describe here what you observed.*

### Steps to reproduce the issue

Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ type:

If you want the environment to be installed in another location, e.g. due to disk space limitations, type:

$ conda env create --file environment.yml --prefix some/other/location/for/cate
$ conda env create --file environment.yml --prefix some/other/location/for/dedop

Next step is to activate the new environment. On Linux/Darwin type:

Expand All @@ -53,11 +53,11 @@ Windows users can omit the `source` command and just type

> activate dedop

You can now safely install and run Cate sources into the new `dedop` environment.
You can now safely install and run DeDop sources into the new `dedop` environment.

(dedop) $ python setup.py develop

To permanently install Cate into the Python environment (not recommended while in development mode!), type:
To permanently install DeDop into the Python environment (not recommended while in development mode!), type:

(dedop) $ python setup.py install

Expand All @@ -82,11 +82,11 @@ If you like to perform L1B product analysis tasks with DeDop using an IPython No

The most up-to-date and complete list of module requirements is found in the project's `environment.yml` file.

To install and run Cate from sources directly, type:
To install and run DeDop from sources directly, type:

$ python setup.py develop

To permanently install Cate into Python (not recommended while in development mode!), type:
To permanently install DeDop into Python (not recommended while in development mode!), type:

$ python setup.py install

Expand Down
49 changes: 0 additions & 49 deletions docs/installation.rst

This file was deleted.

1 change: 1 addition & 0 deletions docs/user_manual.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ User Manual
:maxdepth: 1

user_manual/um_setup
user_manual/um_ws_and_config_concept
user_manual/um_shell
user_manual/um_studio

Expand Down
11 changes: 8 additions & 3 deletions docs/user_manual/um_setup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
Setup
======

Installation
=============
DeDop Shell Installation
=========================

From Binaries
--------------

DeDop is distributed as pre-compiled binaries which can be retrieved from `here <https://github.com/DeDop/dedop/releases/tag/v0.5.3>`_.
DeDop is distributed as pre-compiled binaries which can be retrieved from `here <https://github.com/DeDop/dedop/releases/tag/v1.2.0>`_.
For the windows Windows platforms there is a dedicated installer executable. For Mac OS and Unixes a ZIP file is provided.
All platform distributions have a bundled Python interpreter, that's also the reason why they are quite large in size
(roughly 300 megabytes).
Expand Down Expand Up @@ -50,3 +50,8 @@ After installing from source, you should be able to run the DeDop Shell, try::

dedop --help


DeDop Studio Installation
==========================

Information can be found in `this page <https://github.com/DeDop/dedop-studio>`_.
17 changes: 7 additions & 10 deletions docs/user_manual/um_shell.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,31 @@
DeDop Shell
============

Overview
========

The DeDop tool set currently comprises the *DeDop Shell* - a command-line interface to the
Delay Doppler Processor (DDP) - and *DeDop Studio* - a graphical user interface to the
Delay Doppler Processor (DDP). In this section, you will find the manual for DeDop Shell.
For the manual of DeDop Studio go to :doc:`um_studio`.

The DeDop Shell comprises a single command-line executable, which is called ``dedop`` and is available after installing
the DeDop Shell on your computer. See section :doc:`um_setup` for more information.


.. _workspace_manag:

Workspace Management
====================

**Workspace** in DeDop Shell refers to a space in the file system in which all the requires parts for processing are located.
They include source files, configurations, output files, as well as the Jupyter notebooks. It is possible to have multiple
workspaces and by default they are located under ``$USER_DIR/.dedop/workspaces``.
For example::

C:\\Users\\dummy_user\\.dedop\\workspaces # Windows
/home/dummy_user/.dedop/workspaces # Linux
/Users/dummy_user/.dedop/workspaces # MacOS

Add a new workspace
--------------------

When DeDop Shell runs for the first time, there is no workspace available. An automatic creation of default workspace can
be triggered by running ``dedop input add some/path/to/your/L1A.nc`` or ``dedop run`` command as described
:ref:`here <processing_l1a_l1b>`.

Another (more recommended) way to add a new workspace is by running the following command::
To add a new workspace is by running the following command::

$ dedop w add workspace_name

Expand Down
25 changes: 22 additions & 3 deletions docs/user_manual/um_studio.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ DeDop Studio
=============

DeDop Studio is a desktop application with a primary aim of providing a user-friendly experience for processing L1A files.
It was designed based on the already-existing DeDop Shell, so the behavior is almost the same with its command line counterpart.
It was designed based on the already-existing :doc:`um_shell`, so the behavior is almost the same with its command line counterpart.

.. figure:: ../_static/figures/dedop-studio.png
:scale: 75%
Expand Down Expand Up @@ -107,7 +107,17 @@ To initiate a processing, click ``Run`` button inside **Processor Runs** panel.
required parameters (input file, configuration, and output directory) have been selected. When any of them are missing,
a dialog box will pop up with the information on which field you have to fill up. Otherwise, the processing will be started,
marked by a new entry on the table. You can monitor the progress of the processing and at the moment, because the tool is
capable only running one process at a time, the ``Run`` button is blocked as long as a process is running.
capable only running one process at a time, the ``Run`` button is blocked, displayed as a spinner, as long as a process
is running.

In the end, a process can either be successful or fail. This status is indicated by the icon under ``Action`` column on
the table in **Processor Runs** panel. On the image above, for example, the first three rows indicate that the processes
are successful and when icon is clicked, the page will transition to screen 4,
:ref:`Result & Analysis <analyse_l1b_studio>`. In the case of failure, mouse over on the icon to show a short description
of the error as a tooltip text.

When DeDop Studio is closed, the information in the table is preserved, by storing the data into ``dedop-prefs.json``.
During the next startup of DeDop Studio, this information is loaded and used to populate the table.


.. _analyse_l1b_studio:
Expand All @@ -119,4 +129,13 @@ Analysing L1B Results
:scale: 75%
:align: center


The purpose of this screen is to manage what to do with the result products after a processing. There are two panels:
Output Files and Analysis Configuration. In **Output Files**, users can navigate to different output files in the current
workspace directory, grouped by configurations. By clicking a file name, the said file is selected. This has an implication
on which actions are available, depending on how many files are selected. If only one file is selected, the ``Inspect``
button on **Analysis Configuration** panel is enabled. When two files are selected, the ``Compare`` button is enabled.
Clicking one of these buttons will trigger a creation of a Jupyter notebook suitable for inspecting or comparing the
file(s) that have been selected, and to start a local instance of Jupyter notebook server. This behavior is consistent
with DeDop Shell command :ref:`dedop output compare/inspect <analyse_l1b>`. The dropdown list at the bottom of
**Analysis Configuration** is used to select a notebook file that has been previously created through ``Inspect`` and
``Compare`` buttons.
53 changes: 53 additions & 0 deletions docs/user_manual/um_ws_and_config_concept.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
===================================
Workspace and Configuration Concept
===================================

Workspace
==========

**Workspace** in DeDop Shell refers to a space in the file system in which all the requires parts for processing are located.
They include source files, configurations, output files, as well as the Jupyter notebooks. It is possible to have multiple
workspaces and by default they are located under ``$USER_DIR/.dedop/workspaces``.
For example::

C:\\Users\\dummy_user\\.dedop\\workspaces # Windows
/home/dummy_user/.dedop/workspaces # Linux
/Users/dummy_user/.dedop/workspaces # MacOS

When DeDop Shell runs for the first time, there is no workspace available. An automatic creation of default workspace can
be triggered by running ``dedop input add some/path/to/your/L1A.nc`` or ``dedop run`` command as described
:ref:`here <processing_l1a_l1b>`.

Another (more recommended) way to add a new workspace is by running the following command::

$ dedop w add workspace_name

Upon successful operation, the following responses shall be returned::

created workspace "workspace_name"
current workspace is "workspace_name"

This means that the new workspace has been successfully created and made the current workspace, which means that, unless
explicitly changed, whatever operations being performed after this will happen inside this workspace.

Inside ``workspaces`` directory, there is a file called ``.current``, inside which the name of the current workspace can
be found. When there is no current workspace (eg. because there is no more workspace after a deletion), this file will
be empty.

More information and example on workspace management operations, please go to :ref:`here <workspace_manag>`.

Configuration
==============

**DeDop configuration** refers to a set of configurations (Configuration, Characterization, Constants), which in the file
system are stored as CNF.json, CHD.json, and CST.json. Most of the time, users will need to modify only the **Configuration**.
A configuration is represented by a directory with a name of the configuration name and is located under ``configs``
directory inside a workspace directory. It is possible to have multiple configurations under each workspace and it is
recommended to have a new configuration for different set of configuration values. This way, an output can be easily reproduced
if needed in the future.

As in ``workspaces`` directory, there is a ``.current`` file inside ``configs`` directory. It works following exactly the same
concept: this file has the information on what is the current configuration. In the case of no current configuration,
this file will be empty.

More information and example on configuration management operations, please go to :ref:`here <config_manag>`.
4 changes: 2 additions & 2 deletions tests/webapi/test_websocket.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ def test_config_management(self):
self.assertIn('chd', sentinel_configs)
self.assertIsInstance(sentinel_configs['chd'], dict)
self.assertEqual(len(sentinel_configs['chd']), 13)
self.assertEqual(sentinel_configs['chd']['mean_sat_alt_chd']['value'], 815000.0)
self.assertEqual(sentinel_configs['chd']['brf_sar_chd']['value'], 78.52)
self.assertEqual(sentinel_configs['chd']['mean_sat_alt_chd']['value'], 814500.0)
self.assertEqual(sentinel_configs['chd']['brf_sar_chd']['value'], 78.53069)
self.assertIn('cnf', sentinel_configs)
self.assertIsInstance(sentinel_configs['cnf'], dict)
self.assertEqual(len(sentinel_configs['cnf']), 25)
Expand Down

0 comments on commit 5a68346

Please sign in to comment.