Hi Rohit,
While this is a very interesting question, it would probably belong better
on Stack Overflow <http://stackoverflow.com>, since it's a question
requiring 1-1 support. We do monitor Stack Overflow for good questions in
the tags related to the Google Cloud Platform, so you can either get an
answer by a member of support or from the community itself.
I would suggest separating your two questions into two separate posts.
Remember to include enough code to your question about mean to have a
Minimal example to reproduce your issue, as it will tremendously help other
users in helping you out.
Cheers!
On Sunday, September 27, 2015 at 2:28:33 AM UTC-4, Rohit Jain wrote:
>
> Hi,
>
> can anyone help me with the below code I am some wearied output..don' know
> what exactly to do...
> Also, can someone tell me that how to load an image collection like
> ImageCollection('?(asking about this)') and from the image collection how
> to know which image is where with name.
> I am working on linux and using python.
>
>
> import ee
> ee.Initialize()
> """landsat5Toa =
> ee.ImageCollection('LC80150062013111LGN01').filterDate('2014-3-25').select('B[1]')"""
>
> img = ee.Image('LC80150062013111LGN01').select('B1').unitScale(0, 255)
>
> meanReducer = ee.Reducer.mean()
> sigmaReducer = ee.Reducer.stdDev()
> region = ee.Geometry.Rectangle(77.00133,-51.30404,74.69582,-41.38993 )
> scale = 10000
> mean = img.reduceRegion(meanReducer, region, scale)
> sigma = img.reduceRegion(sigmaReducer, region, scale)
> """mean = landsat5Toa.get('bands')"""
>
>
>
> def stretch(img, mean, sigma):
>
> return ee.Image(0).expression(
>
>
> '((img - mean) / (sigma * 3)) + 0.5', {
> 'img': img,
> 'mean': ee.Image.constant(mean),
> 'sigma': ee.Image.constant(sigma)
> })
>
> print(mean.getInfo())
> print(sigma.getInfo())
>
>
>
>
>
>
>
>
> Output
>
> {u'B1': None}
> {u'B1': None}
>
>
>
> I dont know where I am haveing a problem.
>
> Thank You
>
>
--
You received this message because you are subscribed to the Google Groups
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit
https://groups.google.com/d/msgid/google-appengine/e9b7b54f-cb41-47f3-9411-988b353a4132%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.