Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Python client library for calling the Google Earth Engine API.
1
vote
Storing image collection as array using Google Earth Engine Python API
This is possible, but not for any larger number of pixels. Earth Engine will complain. In practice, you almost certainly would be better off exporting your imagery to Google Drive or Google Cloud Stor …
1
vote
Accepted
Extracting values from ImageCollection at set of points in FeatureCollection
Maybe something like this?
def sample_point(point, image):
return image \
.select(['annualNPP']) \
.sample(
region=point.geometry(),
scale=1000,
…
1
vote
Accepted
Elevation figure for geometry with Google Earth Engine Python API
You didn't provide a complete, running script. If you'd done that, it certainly would have make it easier to help you. Now, just glancing at your script, I see that you're actually not using the eleva …
0
votes
Accepted
How to .map reproject on Image Collection with Python API for Google Earth Engine?
The crsTransform argument cannot be the string 'null'. You either leave it out completely, set it to None, or specify a proper value.
# Just a collection with 10 random images as a dummy setup
collect …
1
vote
Map a function with multiple arguments over an ee.ImageCollection in Google Earth Engine
You cannot do that. The algorithm you specify in map() must take exactly one argument.
If you want that exact signature of your mask_image function, this is one option:
def mask_image(image, fields):
…
1
vote
Accepted
Creating line from 2 points in Google Earth Engine Python API
It seems like the Python API doesn't actually provide a valid default proj value. The docs probaby could use an update to clarify. This works:
point0 = ee.Geometry.Point([0,0])
point1 = ee.Geometry.Po …
2
votes
Accepted
Creating asset folder using Google Earth Engine Python API
You have to use the ee.data.createAsset() method, like so:
import ee
ee.Initialize()
ee.data.createAsset({'type': 'ImageCollection'}, 'users/[your-username]/test-folder')
Note that the type is diff …
0
votes
Accepted
All NDVI Samples over period
You were not very specific in the output you're looking for. Here's one potential approach you can take, that hopefully gets you closer to where you want to get.
Create an image collection for your y …
2
votes
Accepted
Merge a list of ImageCollection into a single ImageCollection in Google Earth Engine Python API
First, a general note: Always try to avoid getInfo() calls whenever you can. It evaluates the value server-side, and returns a client-side object. This often makes your script significantly slower tha …
0
votes
Accepted
Checking if two FeatureCollections are equivalent
As far as I can tell, to implement a server-side, generic, deep equality check between two feature collections would be pretty involved and expensive.
Both should have same properties
Both should hav …
3
votes
Accepted
Calculating null percentage of given image in Google Earth Engine
You can extract the mask from your masked image with ee.Image.mask(). Use that one to determine which pixels to include when you're calculating the area. I'm having a multi-band image, and there's a m …
0
votes
Accepted
Compute the Cartesian product of 2 ee.Lists
What Padmanabha said. Arguably, not really much more code in Python than JavaScript. An explicit conversion from String to Number, with the ability to control the formatting, might be a good idea in a …
1
vote
Accepted
Merging consecutive features based on its properties using recursion in Google Earth Engine ...
As far as I know you cannot recurse without using client-side code. A workaround to this is to iterate at least as many times as the depth of your recursion. I'm giving an example how this can be done …
1
vote
Accepted
ImageCollection contains Images with different CRS
How are you checking which CRS the two images have? To me, both seems to be EPSG: 32631:
roi = ee.Geometry.Polygon(
[[[3.94, 51.6],
[5.3, 51.6],
[5.3, 52.15],
[3.94, 52.15],
[3.94, 51 …
1
vote
Accepted
Error: Can't get band number 0. Image has no bands. (Error code: 3)
You're incorrectly filtering the dates - the full date is required:
.filterDate('2012-01-01','2013-01-01')
You can debug such things by printing intermediate results.
print(filtered_data.getInfo())
…