From 28b9fafdee5267b3434b170793a391fd37532c8d Mon Sep 17 00:00:00 2001
From: Narayana Rao Bhogapurapu <narayanarao.bhogapurapu@gmail.com>
Date: Thu, 3 Oct 2024 12:45:41 -0700
Subject: [PATCH] minor update in htl and htg defaults

---
 src/ich/InSAR_canopy_height.py | 4 ++--
 src/ich/args_in.py             | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/ich/InSAR_canopy_height.py b/src/ich/InSAR_canopy_height.py
index 468d29d..66989fb 100644
--- a/src/ich/InSAR_canopy_height.py
+++ b/src/ich/InSAR_canopy_height.py
@@ -39,8 +39,8 @@ parser = argparse.ArgumentParser(description="Generate canopy height map from In
 
 parser.add_argument("-c", "--correlationFile", dest="corFile", help="Correlation file [0,1]")
 parser.add_argument("-l", "--cal_ht", dest="lidarFile", help="Calibration height file (e.g., LiDAR heights in meters)")
-parser.add_argument("-ll", "--lower_limit", dest="htl", default=None, help="Lower limit of canopy height (m)", type=int)
-parser.add_argument("-ul", "--upper_limit", dest="htg", default=None, help="Upper limit of canopy height (m)", type=int)
+parser.add_argument("-ll", "--lower_limit", dest="htl", default=0, help="Lower limit of canopy height (m)", type=int)
+parser.add_argument("-ul", "--upper_limit", dest="htg", default=0, help="Upper limit of canopy height (m)", type=int)
 parser.add_argument("-w", "--window", dest="window_size", default=10, help="Window size", type=int)
 parser.add_argument("-val", "--validation", dest="validation", default=0, help="Fraction to split for cross-validation", type=float)
 
diff --git a/src/ich/args_in.py b/src/ich/args_in.py
index bb11d95..dd96c8a 100644
--- a/src/ich/args_in.py
+++ b/src/ich/args_in.py
@@ -77,7 +77,7 @@ def rvog_inverse(args):
         # Apply masks to filter out invalid or extreme values
         lidar_ht[lidar_ht == 0] = np.nan
 
-        if args.htl==None and args.htg==None:
+        if args.htl==0 and args.htg==0:
             """ Calculating the upper limit of the heights to be estimated from the LiDAR data 
             Ceiling the upper limit to the closest multiple of 5 for the height at 99.9 percentile """
             args.htl=0
-- 
GitLab