Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Daniel Scheffler
arosics
Commits
6716aeb4
Commit
6716aeb4
authored
Mar 08, 2018
by
Daniel Scheffler
Browse files
Revised previous commit.
Updated version info.
parent
95516841
Changes
4
Hide whitespace changes
Inline
Side-by-side
arosics/CoReg.py
View file @
6716aeb4
...
...
@@ -435,9 +435,14 @@ class COREG(object):
# TODO: replace that function with geoArr.get_subset(zslice=slice(band4match, band4match+1))
# TODO: as soon as all metadata are passed through get_subset()
zslice
=
slice
(
geoArr_cr
.
band4match
,
geoArr_cr
.
band4match
+
1
)
geoArr_cr
.
bandnames
=
list
(
np
.
array
(
list
(
geoArr_cr
.
_bandnames
))[
zslice
])
geoArr_cr
.
metadata
=
None
if
geoArr_cr
.
_metadata
is
None
else
\
geoArr_cr
.
_metadata
[
list
(
np
.
array
(
range
(
geoArr_cr
.
bands
))[
zslice
])].
copy
()
if
geoArr_cr
.
_bandnames
:
geoArr_cr
.
bandnames
=
list
(
np
.
array
(
list
(
geoArr_cr
.
_bandnames
))[
zslice
])
if
geoArr_cr
.
_metadata
is
not
None
:
geoArr_cr
.
metadata
=
\
geoArr_cr
.
_metadata
[
list
(
np
.
array
(
range
(
len
(
geoArr_cr
.
_metadata
.
columns
)))[
zslice
])].
copy
()
return
geoArr_cr
if
self
.
grid2use
==
'ref'
:
...
...
arosics/__init__.py
View file @
6716aeb4
...
...
@@ -12,8 +12,8 @@ from arosics.Tie_Point_Grid import Tie_Point_Grid
__author__
=
"""Daniel Scheffler"""
__email__
=
'daniel.scheffler@gfz-potsdam.de'
__version__
=
'0.8.
3
'
__versionalias__
=
'2018-03-0
7
_01'
__version__
=
'0.8.
4
'
__versionalias__
=
'2018-03-0
8
_01'
__all__
=
[
'COREG'
,
'COREG_LOCAL'
,
'DESHIFTER'
,
...
...
setup.py
View file @
6716aeb4
...
...
@@ -28,7 +28,7 @@ test_requirements = requirements + ['coverage', 'nose', 'nose-htmloutput', 'redn
setup
(
name
=
'arosics'
,
version
=
'0.8.
3
'
,
version
=
'0.8.
4
'
,
description
=
"An Automated and Robust Open-Source Image Co-Registration Software for Multi-Sensor Satellite Data"
,
long_description
=
readme
+
'
\n\n
'
+
history
,
author
=
"Daniel Scheffler"
,
...
...
tests/test_COREG_LOCAL.py
View file @
6716aeb4
...
...
@@ -86,3 +86,39 @@ class CompleteWorkflow_INTER1_S2A_S2A(unittest.TestCase):
#
# # Part 2: Saving the results of each testsuite and the query for the job.status in individual variables.
# testResult = unittest.TextTestRunner(verbosity=2).run(alltests)
class
TestBandnames
(
unittest
.
TestCase
):
def
setUp
(
self
):
import
dill
with
open
(
'/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/CRL_argskwargs.dill'
,
'rb'
)
as
inF
:
argskwargs
=
dill
.
load
(
inF
)
argskwargs
[
'im_ref'
]
=
'/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/ref_image.tif'
argskwargs
[
'im_tgt'
]
=
'/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/L2A_T32UPV_20170430T103021_B05_20m.jp2'
argskwargs
[
'q'
]
=
False
self
.
argskwargs
=
argskwargs
def
test
(
self
):
crl
=
COREG_LOCAL
(
**
self
.
argskwargs
)
crl
.
tiepoint_grid
crl
.
correct_shifts
()
# class TestBandnames(unittest.TestCase):
# def setUp(self):
# import dill
# with open('/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/CRL_argskwargs_60m.dill', 'rb') as inF:
# argskwargs = dill.load(inF)
#
# argskwargs['im_ref'] = '/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/ref_image.tif'
# argskwargs['im_tgt'] = '/home/gfz-fe/scheffler/temp/coreg_bug_bandnames/L2A_T32UPV_20170430T103021_B01_60m.jp2'
# argskwargs['q'] = False
#
# self.argskwargs = argskwargs
#
# def test(self):
# crl = COREG_LOCAL(**self.argskwargs)
# crl.tiepoint_grid
# crl.correct_shifts()
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment