From b953aa5e33997cde026ac641fb578e59ee483c67 Mon Sep 17 00:00:00 2001 From: Dugal Harris Date: Sat, 14 Oct 2023 14:55:22 +0200 Subject: [PATCH] remove completed to dos --- simple_ortho/__init__.py | 2 +- simple_ortho/cli.py | 1 + simple_ortho/io.py | 1 - simple_ortho/ortho.py | 1 - tests/test_io.py | 5 ----- 5 files changed, 2 insertions(+), 8 deletions(-) diff --git a/simple_ortho/__init__.py b/simple_ortho/__init__.py index d616098..9422c79 100644 --- a/simple_ortho/__init__.py +++ b/simple_ortho/__init__.py @@ -18,7 +18,7 @@ import pathlib # enable on-demand download and caching of proj transformation grids -os.environ.update(PROJ_NETWORK='ON', PROJ_ONLY_BEST_DEFAULT='ON') +os.environ.update(PROJ_NETWORK='ON') # path to package root TODO: remove with deprecated simple-ortho CLI if '__file__' in globals(): diff --git a/simple_ortho/cli.py b/simple_ortho/cli.py index 5b6924e..b299ce6 100644 --- a/simple_ortho/cli.py +++ b/simple_ortho/cli.py @@ -769,3 +769,4 @@ def parse_args(argv=None): cli() # TODO: test CLI exceptions are meaningful +# TODO: add radians option for CSV files \ No newline at end of file diff --git a/simple_ortho/io.py b/simple_ortho/io.py index 84b3026..9aa980a 100644 --- a/simple_ortho/io.py +++ b/simple_ortho/io.py @@ -938,7 +938,6 @@ def write_int_param( raise FileExistsError(f"Interior parameter file exists: '{filename}'.") filename.unlink() - # TODO: just use cam_type in oty format? # convert 'cam_type' key to 'type' & make the converted item the first in the dict yaml_dict = {} for cam_id, int_param in int_param_dict.items(): diff --git a/simple_ortho/ortho.py b/simple_ortho/ortho.py index 3d8b178..620814a 100644 --- a/simple_ortho/ortho.py +++ b/simple_ortho/ortho.py @@ -259,7 +259,6 @@ def _mask_dem( Crop and mask the given DEM to the ortho polygon bounds, returning the adjusted DEM and corresponding transform. """ - # TODO: trace rays in a thread pool? def inv_transform(transform: rio.Affine, xy: np.array): """ Return the center (j, i) pixel coords for the given transform and world (x, y) coordinates. """ return np.array(~(transform * rio.Affine.translation(0.5, 0.5)) * xy) diff --git a/tests/test_io.py b/tests/test_io.py index 84166b9..2bdbdeb 100644 --- a/tests/test_io.py +++ b/tests/test_io.py @@ -608,8 +608,3 @@ def test_oty_reader_crs(ngi_oty_ext_param_file: Path, ngi_crs: str): """ Test OtyReader reads the crs correctly. """ reader = io.OtyReader(ngi_oty_ext_param_file, crs=None) assert reader.crs == rio.CRS.from_string(ngi_crs) - - -# TODO: radians in CSV -# - perhaps add second fixture that rewrites e.g. ngi_xyz_opk.csv in radians (perhaps a parameterised fixture), -# then a test that reads both radians and degrees files and compares results. could do same for odm_lla_rpy.csv.