Skip to content

Reflectometry rewrite #61

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 88 commits into from
Dec 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
88 commits
Select commit Hold shift + click to select a range
6dee37d
first draft and changing data loader structure
nvaytet Oct 1, 2021
24ea600
load amor data and convert to wavelength
nvaytet Oct 1, 2021
dcecd1a
Merge branch 'main' into new_reflectometry_data
nvaytet Oct 4, 2021
6dbb87e
Merge branch 'main' into new_reflectometry_data
nvaytet Oct 8, 2021
9de8eaa
Merge branch 'main' into new_reflectometry_data
nvaytet Oct 11, 2021
0056e76
manually broadcast positions to events to avoid automatic broadcast o…
nvaytet Oct 18, 2021
35a1eb9
use binning in wavelength to simplify theta calculation
nvaytet Oct 19, 2021
b9d0133
add qz coord
nvaytet Oct 19, 2021
20239e2
Merge branch 'new_reflectometry_data' of github.com:scipp/ess into ne…
nvaytet Oct 21, 2021
87dc4e7
start adding conversion graphs
nvaytet Nov 5, 2021
ee80db7
add skeleton notebook for amor reduction
nvaytet Nov 5, 2021
6eec445
mroe cleanup
nvaytet Nov 8, 2021
7925e26
remove old files, we'll add functionality back in from the diff
nvaytet Nov 8, 2021
8e03086
docstrings
nvaytet Nov 8, 2021
9a635b0
remove utils, add file managing with pooch and update ntoebook
nvaytet Nov 8, 2021
efdc75c
update env file
nvaytet Nov 8, 2021
d31e7de
Merge branch 'main' into new_reflectometry_data
nvaytet Nov 8, 2021
425dc4e
flake8
nvaytet Nov 8, 2021
7f01825
fix python tests
nvaytet Nov 8, 2021
05f8359
fix unreleased erf function error
nvaytet Nov 8, 2021
08f99fe
add pythreejs and add normalization by supermirror in notebook
nvaytet Nov 8, 2021
96edd88
add graphviz
nvaytet Nov 9, 2021
881e215
workaround astype until 0.9 is released
nvaytet Nov 9, 2021
1c78219
scippneutron version 0.4.1
nvaytet Nov 12, 2021
5fddb8e
remove TODO after 0.9 release
nvaytet Nov 15, 2021
9fd8431
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
838c4b8
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
490bfa9
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
584bec8
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
e163e66
Update src/ess/reflectometry/conversions.py
nvaytet Nov 17, 2021
8606e3b
Update src/ess/reflectometry/conversions.py
nvaytet Nov 17, 2021
c105785
Update src/ess/reflectometry/conversions.py
nvaytet Nov 17, 2021
c97d2b9
Update src/ess/reflectometry/conversions.py
nvaytet Nov 17, 2021
9dad31c
Update src/ess/reflectometry/io/load.py
nvaytet Nov 17, 2021
74a2385
Update src/ess/reflectometry/io/load.py
nvaytet Nov 17, 2021
3a63179
Update src/ess/reflectometry/io/load.py
nvaytet Nov 17, 2021
a453c76
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
3717d47
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
33fbf9a
Update src/ess/amor/io/load.py
nvaytet Nov 17, 2021
3b60bba
make a start on using Chopper class from WFM code
nvaytet Nov 18, 2021
9cdaaca
use Chopper class for reflectometry
nvaytet Nov 19, 2021
7af4611
update conversion graph
nvaytet Nov 19, 2021
d4ae54e
update notebook
nvaytet Nov 19, 2021
be34444
fix python tests
nvaytet Nov 19, 2021
3d36da8
remove unused files
nvaytet Nov 19, 2021
f818bc7
remove intermediate step
nvaytet Nov 22, 2021
6645f64
update q_grid tests
nvaytet Nov 22, 2021
f5a786b
use theta in calculation of Q
nvaytet Nov 23, 2021
e1e9881
simply remove x from gravity correction equation
nvaytet Nov 23, 2021
fafbf02
go back to the original graph with 2theta
nvaytet Nov 24, 2021
a9bee58
do not use two_theta in unit conversion. Compute theta using omega angle
nvaytet Nov 29, 2021
e5f7935
cleanup and update docs api
nvaytet Nov 29, 2021
3be9a9d
make amor conversion graph and amor instrument view
nvaytet Nov 30, 2021
5195a69
update notebook
nvaytet Nov 30, 2021
eb3b9d6
put the code to generate the WFM figures in the notebook instead of u…
nvaytet Nov 30, 2021
5678294
better syntax for q_grid function
nvaytet Dec 1, 2021
6a3cfc0
better error message in q_grid
nvaytet Dec 1, 2021
794b96b
tidy up reference in docs
nvaytet Dec 1, 2021
6323932
new update to amor api reference
nvaytet Dec 7, 2021
9f120c5
rename conversion graphs
nvaytet Dec 7, 2021
60b5f05
remove Chopper class and make free functions in chopper module instead
nvaytet Dec 7, 2021
4d0e447
start changing choppers to data arrays
nvaytet Dec 7, 2021
e1297ec
start making changes to wfm code to account for new chopper structure
nvaytet Dec 7, 2021
e32c8ba
fix reducing wfm data notebook
nvaytet Dec 8, 2021
0466bec
update intro to wfm notebook
nvaytet Dec 8, 2021
e898683
fix python tests
nvaytet Dec 8, 2021
2493591
fix ODIN beamline
nvaytet Dec 8, 2021
120ad22
change q_grid to linlogspace, use in-place ops in coord transform
nvaytet Dec 8, 2021
e4853a6
use sc.erf and change z_offset implementation
nvaytet Dec 8, 2021
b928aad
flake8
nvaytet Dec 8, 2021
2e00167
fix copyright year
nvaytet Dec 8, 2021
e1acf3c
replace old Chopper constructor with a free function make_chopper
nvaytet Dec 9, 2021
d8c44a6
use make_chopper in bemalines
nvaytet Dec 9, 2021
5e4615e
better use of in-place ops in coord transforms
nvaytet Dec 9, 2021
d4ed7c2
update comment in docstring
nvaytet Dec 9, 2021
4015110
add make_chopper docstring
nvaytet Dec 9, 2021
1f0ecc3
use unit of L2
nvaytet Dec 9, 2021
b6d2816
add more docstrings in chopper.utils
nvaytet Dec 9, 2021
aaba230
flake8
nvaytet Dec 9, 2021
a3fb10c
update docs notebook
nvaytet Dec 9, 2021
e4da96f
update wfm notebook
nvaytet Dec 9, 2021
e1df1ab
try to cleanup api docs
nvaytet Dec 9, 2021
6092471
add toctrees in reference docs
nvaytet Dec 9, 2021
36c0e7b
branching optimization in tramsform coords when considering either th…
nvaytet Dec 9, 2021
e7889a5
update release notes
nvaytet Dec 9, 2021
4310120
use issorted
nvaytet Dec 10, 2021
99438ce
flake8
nvaytet Dec 10, 2021
785dbc6
issorted().value -> allsorted()
nvaytet Dec 10, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ requirements:
- sphinx_rtd_theme
- gitpython
run:
- scippneutron=0.4.*
- scippneutron>=0.4.1
- tifffile
- astropy
- matplotlib
Expand Down
30 changes: 30 additions & 0 deletions docs/_templates/ess-class-template.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{ fullname | escape | underline }}

.. currentmodule:: {{ module }}

.. autoclass:: {{ objname }}
:members:

{% block methods %}
.. automethod:: __init__

{% if methods %}
.. rubric:: {{ _('Methods') }}

.. autosummary::
{% for item in methods %}
~{{ name }}.{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

{% block attributes %}
{% if attributes %}
.. rubric:: {{ _('Attributes') }}

.. autosummary::
{% for item in attributes %}
~{{ name }}.{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}
66 changes: 66 additions & 0 deletions docs/_templates/ess-module-template.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{{ fullname | escape | underline}}

.. automodule:: {{ fullname }}

{% block attributes %}
{% if attributes %}
.. rubric:: {{ _('Module Attributes') }}

.. autosummary::
:toctree:
{% for item in attributes %}
{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

{% block functions %}
{% if functions %}
.. rubric:: {{ _('Functions') }}

.. autosummary::
:toctree:
{% for item in functions %}
{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

{% block classes %}
{% if classes %}
.. rubric:: {{ _('Classes') }}

.. autosummary::
:toctree:
:template: ess-class-template.rst
{% for item in classes %}
{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

{% block exceptions %}
{% if exceptions %}
.. rubric:: {{ _('Exceptions') }}

.. autosummary::
:toctree:
{% for item in exceptions %}
{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

{% block modules %}
{% if modules %}
.. rubric:: Modules

.. autosummary::
:toctree:
:template: ess-module-template.rst
:recursive:
{% for item in modules %}
{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}
34 changes: 34 additions & 0 deletions docs/about/release-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,40 @@
Release Notes
=============

v0.2.0 (unreleased)
-------------------

Features
~~~~~~~~

Breaking changes
~~~~~~~~~~~~~~~~

* A major rewrite of the reflectometry code was undertaken `#61 <https://github.com/scipp/ess/pull/61>`_:

* The reflectometry and Amor Data classes were removed in favour of a formalism consisting of free-functions that accept Scipp DataArrays and Datasets.
* Moved the chopper class from the `wfm` submodule to free functions in its own ``choppers`` module.
* The unit conversion (computing wavelength and Q) now use ``transform_coords``.
* The Amor reduction notebook from ``ess-notebooks`` has been imported into the ``ess`` repository.

Bugfixes
~~~~~~~~

Deprecations
~~~~~~~~~~~~

Stability, Maintainability, and Testing
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Contributors
~~~~~~~~~~~~

Owen Arnold :sup:`b, c`\ ,
Simon Heybrock :sup:`a`\ ,
Andrew McCluskey :sup:`a`\ ,
Samuel Jones :sup:`b`\ ,
and Neil Vaytet :sup:`a`\

v0.1.0 (September 2021)
-----------------------

Expand Down
6 changes: 4 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
# -- Project information -----------------------------------------------------

project = u'ess'
copyright = u'2020 scipp ess contributors'
copyright = u'scipp ess contributors'
copyright = u'2021 Scipp contributors'
copyright = u'scipp contributors'

# The full version, including alpha/beta/rc tags
version = u''
Expand All @@ -51,6 +51,8 @@
'nbsphinx',
]

autodoc_typehints = 'description'

# autodocs includes everything, even irrelevant API internals. autosummary
# looks more suitable in the long run when the API grows.
# For a nice example see how xarray handles its API documentation.
Expand Down
6 changes: 3 additions & 3 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ Documentation
:maxdepth: 3
:caption: Instruments

instruments/amor
instruments/amor/amor

.. toctree::
:maxdepth: 3
:caption: Techniques

techniques/reflectometry
techniques/wfm
techniques/reflectometry/reflectometry
techniques/wfm/wfm

.. toctree::
:caption: About
Expand Down
4 changes: 2 additions & 2 deletions docs/instruments/amor.rst → docs/instruments/amor/amor.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ Amor
.. toctree::
:maxdepth: 4

amor/amor_data
amor/tools
amor_reduction
reference
7 changes: 0 additions & 7 deletions docs/instruments/amor/amor_data.rst

This file was deleted.

Loading