diff --git a/Alignment v2.ipynb b/Alignment v2.ipynb index f82ea663..96bbe58b 100644 --- a/Alignment v2.ipynb +++ b/Alignment v2.ipynb @@ -35,9 +35,7 @@ "cell_type": "code", "execution_count": null, "id": "7426068b", - "metadata": { - "scrolled": false - }, + "metadata": {}, "outputs": [], "source": [ "import os, glob\n", @@ -55,10 +53,10 @@ "# imagePath = Path(\"./data/REDEDGE-MX-DUAL\")\n", "\n", "# # these will return lists of image paths as strings \n", - "# imageNames = list(imagePath.glob('IMG_0007_*.tif'))\n", + "# imageNames = list(imagePath.glob('IMG_0431_*.tif'))\n", "# imageNames = [x.as_posix() for x in imageNames]\n", "\n", - "# panelNames = list(imagePath.glob('IMG_0001_*.tif'))\n", + "# panelNames = list(imagePath.glob('IMG_0000_*.tif'))\n", "# panelNames = [x.as_posix() for x in panelNames]\n", "\n", "# imagePath = Path(\"./data/REDEDGE-MX\")\n", @@ -316,9 +314,7 @@ "cell_type": "code", "execution_count": null, "id": "12c2a278", - "metadata": { - "scrolled": false - }, + "metadata": {}, "outputs": [], "source": [ "# from micasense.imageutils import brovey_pan_sharpen,radiometric_pan_sharpen\n", @@ -449,9 +445,7 @@ "cell_type": "code", "execution_count": null, "id": "8626c90b", - "metadata": { - "scrolled": false - }, + "metadata": {}, "outputs": [], "source": [ "# figsize=(30,23) # use this size for full-image-resolution display\n", @@ -771,9 +765,7 @@ "cell_type": "code", "execution_count": null, "id": "c0250872", - "metadata": { - "scrolled": false - }, + "metadata": {}, "outputs": [], "source": [ "x_band = red_band\n", diff --git a/Alignment-10Band.ipynb b/Alignment-10Band.ipynb index b8b100ad..83b70f6f 100644 --- a/Alignment-10Band.ipynb +++ b/Alignment-10Band.ipynb @@ -40,8 +40,8 @@ "paneCap = None\n", "\n", "imagePath = os.path.join('.','data','REDEDGE-MX-DUAL')\n", - "imageNames = glob.glob(os.path.join(imagePath,'IMG_0007_*.tif'))\n", - "panelNames = glob.glob(os.path.join(imagePath,'IMG_0001_*.tif'))\n", + "imageNames = glob.glob(os.path.join(imagePath,'IMG_0431_*.tif'))\n", + "panelNames = glob.glob(os.path.join(imagePath,'IMG_0000_*.tif'))\n", "\n", "# Allow this code to align both radiance and reflectance images; bu excluding\n", "# a definition for panelNames above, radiance images will be used\n", diff --git a/micasense/metadata.py b/micasense/metadata.py index eda06fbf..9aa7ffb1 100644 --- a/micasense/metadata.py +++ b/micasense/metadata.py @@ -63,7 +63,7 @@ def get_item(self, item, index=None): val = self.exif[0][item] if index is not None: try: - if isinstance(val, pytz.unicode): + if isinstance(val, unicode): val = val.encode('ascii', 'ignore') except NameError: # throws on python 3 where unicode is undefined @@ -84,7 +84,7 @@ def size(self, item): """get the size (length) of a metadata item""" val = self.get_item(item) try: - if isinstance(val, pytz.unicode): + if isinstance(val, unicode): val = val.encode('ascii', 'ignore') except NameError: # throws on python 3 where unicode is undefined