Skip to content

Commit

Permalink
Remove import and rearrange spectral subset code
Browse files Browse the repository at this point in the history
  • Loading branch information
javerbukh committed Jul 16, 2024
1 parent a63c5b1 commit 035ef71
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
5 changes: 2 additions & 3 deletions jdaviz/configs/default/plugins/subset_plugin/subset_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -673,10 +673,9 @@ def _import_spectral_regions(self, spec_region, mode=NewMode):
OrMode will create a composite subset with each subregion corresponding
to a subregion of a single subset.
"""
viewer_name = self.app._jdaviz_helper._default_spectrum_viewer_reference_name
spectrum_viewer = self.app.get_viewer(viewer_name)
for sub_region in spec_region:
viewer_name = self.app._jdaviz_helper._default_spectrum_viewer_reference_name
spectrum_viewer = self.app.get_viewer(viewer_name)
spectrum_viewer.toolbar.active_tool = spectrum_viewer.toolbar.tools['bqplot:xrange']
self.app.session.edit_subset_mode.mode = mode
spectrum_viewer.apply_roi(XRangeROI(sub_region.lower.value, sub_region.upper.value))

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import warnings
import pytest
import json

import numpy as np
from astropy.nddata import NDData
Expand Down

0 comments on commit 035ef71

Please sign in to comment.