Skip to content

Instantly share code, notes, and snippets.

View prl900's full-sized avatar

Pablo Rozas Larraondo prl900

View GitHub Profile
package main
import (
"bufio"
"golang.org/x/image/tiff"
"image/png"
"os"
)
func main() {
@prl900
prl900 / aws_modis_downloader.go
Created April 6, 2018 04:39
Downloader for AWS Modis data
package main
import (
"encoding/xml"
"fmt"
"io/ioutil"
"net/http"
"path"
"os"
"io"
@prl900
prl900 / gcp_modis_uploader.go
Created April 6, 2018 05:05
Upload local copy of Modis tiles
package main
import (
"fmt"
"io/ioutil"
//"os"
"path"
"cloud.google.com/go/storage"
"golang.org/x/net/context"
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
package main
import (
"encoding/gob"
"fmt"
"image"
"image/png"
"net/http"
"strconv"
package main
import (
"encoding/gob"
"fmt"
"net/http"
"strconv"
itsk "github.com/prl900/intersekt"
"google.golang.org/appengine"
@prl900
prl900 / cog.go
Created May 3, 2018 00:28
Testing remote access to COG files hosted on AWS S3
package main
import (
"github.com/terrascope/gocog"
"fmt"
"image"
"image/png"
"net/http"
"os"
)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import gdal
from osgeo import osr
import numpy as np
ras = np.load("/Users/pablo/Downloads/test.npy")
drv = gdal.GetDriverByName("GTiff")
ds = drv.Create("/Users/pablo/Downloads/gbdx.tif", 8765, 10000, 1, gdal.GDT_Float32)
proj = osr.SpatialReference()
proj.ImportFromEPSG(4326)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.