This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| # /// script | |
| # dependencies = ["geopandas", "rioxarray", "tyro", "opera_utils"] | |
| # /// | |
| """Create a GeoParquet file from multi-date InSAR displacement GeoTIFFs. | |
| Optionally mask by similarity and coherence thresholds. | |
| Example CLI usage (with tyro): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """ | |
| Validation script to compare Python and Fortran implementations | |
| of solid earth tide calculations across different times and locations. | |
| """ | |
| import datetime as dt | |
| import numpy as np | |
| import pandas as pd | |
| from pathlib import Path |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """Python conversion of MIDAS velocity calculation. | |
| Original code: http://geodesy.unr.edu/MIDAS_release.tar | |
| Original author: Geoff Blewitt. Copyright (C) 2015. | |
| When using these velocities in publications please cite: | |
| Blewitt, G., C. Kreemer, W.C. Hammond, and J. Gazeaux (2016). MIDAS robust trend | |
| estimator for accurate GPS station velocities without step detection, Journal |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| for item in COH12 COH24 COH36 rho tau; do | |
| s5cmd --numworkers 10 --no-sign-request cp "s3://sentinel-1-global-coherence-earthbigdata/data/mosaics/*vv*${item}*" . | |
| done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| git tag --list | sort --version-sort | xargs -n1 gh release view |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import requests | |
| import re | |
| import random | |
| from rich.console import Console | |
| from rich.panel import Panel | |
| from rich.text import Text | |
| url = "https://raw.githubusercontent.com/nrrb/tao-te-ching/master/Ursula%20K%20Le%20Guin.md" | |
| def get_random_chapter(): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from starlette import responses | |
| from titiler.core.algorithm import algorithms as default_algorithms | |
| from titiler.core.errors import DEFAULT_STATUS_CODES, add_exception_handlers | |
| from titiler.core.factory import TilerFactory | |
| from fastapi import FastAPI | |
| from .titiler_algorithms import Phase | |
| app = FastAPI(title="Bowser") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from os import fspath | |
| import numpy as np | |
| from osgeo import gdal | |
| from dolphin import io, stitching, utils | |
| def compute_boi(ifg_file1: str, ifg_file2: str, looks: tuple[int, int] = (1, 1)) -> np.ndarray: | |
| assert io.get_raster_crs(ifg_file1) == io.get_raster_crs(ifg_file2) | |
| (left, bottom, right, top), nodata = stitching.get_combined_bounds_nodata( | |
| ifg_file1, ifg_file2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| from numba import njit | |
| @njit | |
| def f(arr): | |
| s = 0 | |
| i = 0 | |
| while i < len(arr): | |
| s += arr[i] |