Skip to content
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

Fixes ahead of v0.13 release #1677

Merged
merged 7 commits into from
Apr 27, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ Full changelog
v0.13.0 (unreleased)
--------------------

* Fixed a bug that caused vectors to not correctly be flipped when
flipping the x/y limits of the plot. [#1678]

* Added a CSV and HDF5 data/subset exporter. [#1676]

* Started adding helpful information dialogs that can be
Expand Down
5 changes: 3 additions & 2 deletions doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ Glue application to the more advanced ways of interacting with Glue from Python.

.. note:: For any questions or help with using glue, you can always join the
`user support mailing list <https://groups.google.com/forum/#!forum/glue-viz>`_
or ask questions on our `Gitter channel <https://gitter.im/glue-viz/glue>`_!
or ask questions on `Slack <https://glueviz.slack.com>`_
(note that you will need to sign up for an account `here <https://glueviz-slack-invite.herokuapp.com>`_).

Using the Glue application
--------------------------
Expand Down Expand Up @@ -145,7 +146,7 @@ the following two references:
* `Robitaille et al (2017) glueviz v0.10: multidimensional data exploration
<https://zenodo.org/record/293197>`_

The first is a conference proceedings describing glue, while the second is a
The first is a conference proceedings describing glue, while the second is the
software itself.

Publications
Expand Down
19 changes: 12 additions & 7 deletions doc/whatsnew/whatsnew.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ If instead you installed glue with pip, you can update with::

pip install glueviz[all] --upgrade

If you have any questions about any of the functionality described below or
about glue in general, you can find information :ref:`here
<help>` about contacting us and/or
reporting issues.

.. _whatsnew_013:

What's new in glue v0.13?
Expand Down Expand Up @@ -56,13 +61,13 @@ linked by world coordinates instead of pixel coordinates:

.. image:: images/v0.13/reprojection.jpg
:align: center
:width: 400
:width: 500

For astronomers reading this, this means being able to overplot images and
cubes with different WCS transformations, provided that you have set up links
between the world coordinates - and this includes being able to show 2D images
and 3D spectral cubes at the same time (if you do this, note that the reference
data needs to be the dataset you want to slice over).
For astronomers: this means being able to overplot images and cubes with
different WCS transformations, provided that you have set up links between the
world coordinates - and this includes being able to show 2D images and 3D
spectral cubes at the same time (if you do this, note that the reference data
needs to be the dataset you want to slice over, i.e. the cube, not the 2D image).

Arithmetic attribute editor
---------------------------
Expand Down Expand Up @@ -117,7 +122,7 @@ provides a more intuitive interface for exporting data and subsets:
:align: center
:width: 350

This dialog is accessible via the 'Export Data/Subsets' button in the toolbar:
This dialog is accessible via the **Export Data/Subsets** button in the toolbar:

.. image:: images/v0.13/export_data_button.png
:align: center
Expand Down
1 change: 1 addition & 0 deletions glue/_deps.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ def version(self):
Dependency('qtpy', 'Required', min_version='1.2'),
Dependency('setuptools', 'Required', min_version='1.0'),
Dependency('numpy', 'Required', min_version='1.9'),
Dependency('bottleneck', 'Required', min_version='1.2'),
Dependency('matplotlib', 'Required for plotting', min_version='2.0'),
Dependency('pandas', 'Adds support for Excel files and DataFrames', min_version='0.14'),
Dependency('astropy', 'Used for FITS I/O, table reading, and WCS Parsing', min_version='1.3'),
Expand Down
6 changes: 3 additions & 3 deletions glue/viewers/image/qt/profile_viewer_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ def activate(self):
proceed = info('Creating a profile viewer',
'Note: profiles are '
'computed from datasets and subsets collapsed along all but one '
'dimension. To view the profile of part of the data, you can draw '
'and update a subset in the current image viewer and the profile '
'will update accordingly.', setting='show_info_profile_open')
'dimension. To view the profile of part of the data, once you '
'click OK you can draw and update a subset in the current '
'image viewer and the profile will update accordingly.', setting='show_info_profile_open')

if not proceed:
return
Expand Down
2 changes: 1 addition & 1 deletion glue/viewers/scatter/layer_artist.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ def _update_data(self, changed):
self.vector_artist = self.axes.quiver(x, y, vx, vy, units='width',
pivot=self.state.vector_origin,
headwidth=hw, headlength=hl,
scale_units='width',
scale_units='width', angles='xy',
scale=10 / self.state.vector_scaling * vmax)
self.mpl_artists[self.vector_index] = self.vector_artist

Expand Down
1 change: 1 addition & 0 deletions glue/viewers/scatter/python_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ def python_export_scatter_layer(layer, *args):
headwidth=hw, headlength=hl,
scale_units='width',
scale=scale,
angles='xy',
alpha=layer.state.alpha,
zorder=layer.state.zorder)

Expand Down
24 changes: 20 additions & 4 deletions glue/viewers/scatter/qt/layer_style_editor.ui
Original file line number Diff line number Diff line change
Expand Up @@ -732,10 +732,18 @@
</spacer>
</item>
<item row="2" column="4">
<widget class="QComboBox" name="combosel_yerr_att"/>
<widget class="QComboBox" name="combosel_yerr_att">
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
</property>
</widget>
</item>
<item row="1" column="4">
<widget class="QComboBox" name="combosel_xerr_att"/>
<widget class="QComboBox" name="combosel_xerr_att">
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QCheckBox" name="bool_xerr_visible">
Expand Down Expand Up @@ -823,7 +831,11 @@
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="combosel_vx_att"/>
<widget class="QComboBox" name="combosel_vx_att">
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
Expand All @@ -842,7 +854,11 @@
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="combosel_vy_att"/>
<widget class="QComboBox" name="combosel_vy_att">
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToMinimumContentsLength</enum>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_vector_x">
Expand Down
7 changes: 7 additions & 0 deletions glue/viewers/scatter/qt/tests/test_python_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,13 @@ def test_vector_cartesian_cmap(self, tmpdir):
self.viewer.state.layers[0].cmap = plt.cm.BuGn
self.test_vector_cartesian(tmpdir)

def test_vector_cartesian_xflip(self, tmpdir):
# Regression test for a bug that caused vectors to not be flipped
self.viewer.state.layers[0].vector_mode = 'Cartesian'
self.viewer.state.layers[0].vx_att = self.data.id['h']
self.viewer.state.flip_x()
self._vector_common(tmpdir)

def test_subset(self, tmpdir):
self.data_collection.new_subset_group('mysubset', self.data.id['a'] > 0.5)
self.assert_same(tmpdir)
Expand Down