From 2cc1d4db38b4f04eacf801bc17b115fa704e1781 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jon=20Haitz=20Legarreta=20Gorro=C3=B1o?= Date: Tue, 10 Dec 2024 15:43:04 -0500 Subject: [PATCH] ENH: Remove Python 2.x legacy conditional import statement Remove Python 2.x legacy conditional import statement: import `OrderedDict` from `collections`. Support for Python 2.x was dropped following the discussion in ttps://github.com/demianw/tract_querier/pull/5. --- tract_querier/tract_math/tensor_operations.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/tract_querier/tract_math/tensor_operations.py b/tract_querier/tract_math/tensor_operations.py index 3b4350d..53543bc 100644 --- a/tract_querier/tract_math/tensor_operations.py +++ b/tract_querier/tract_math/tensor_operations.py @@ -3,11 +3,7 @@ from . import tract_operations from ..tensor import scalar_measures -try: - from collections import OrderedDict -except ImportError: # Python 2.6 fix - from ordereddict import OrderedDict - +from collections import OrderedDict def compute_all_measures(tractography, desired_keys_list, scalars=None, resolution=None):