Yep Adam, you're right.
Turning into string seems to turn false to true. Good point but it
doesn't solve my troubles completely.

I try to copy paste some code and output to show you some weird
things.

Regards,

Pierre

On 4 sep, 19:31, Adam <[EMAIL PROTECTED]> wrote:
> Should you be using:
>
>    str(hashPoi) > str(hashSW)
>
> or Geostring instead?
>
> A
>
> On Sep 4, 6:59 am, Pierre <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > Here's an example :
> > [GCC 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)] on linux2
> > Type "help", "copyright", "credits" or "license" for more information.>>> 
> > import geohash
> > >>> hashSW = geohash.Geohash((1.5765380859375,42.894076403348976))
> > >>> hashNE = geohash.Geohash((6.1907958984375,44.3002644115815))
> > >>> hashPoi = geohash.Geohash((3.867915,43.733638))
> > >>> hashPoi > hashSW
> > False
> > >>> hashPoi < hashNE
>
> > True
>
> > With geoIndex :>>> hashSW = 
> > geohash.Geoindex((1.5765380859375,42.894076403348976))
> > >>> hashNE = geohash.Geoindex((6.1907958984375,44.3002644115815))
> > >>> hashPoi = geohash.Geoindex((3.867915,43.733638))
> > >>> hashPoi > hashSW
> > False
> > >>> hashPoi < hashNE
>
> > True
>
> > I might be missing something but I thought : hash(SW) < hashPoi <
> > hash(NE)
>
> > How do you use it and do you find something different ?
>
> > Regards,
>
> > Pierre
>
> > On 4 sep, 12:33, Ubaldo Huerta <[EMAIL PROTECTED]> wrote:
>
> > > Do you have a example of a point whose geohash value isn't greater
> > > than SW, NE geohashes?
>
> > > I've tried, in  the python interpreter, many examples, and haven't
> > > observed what you're describing. It's pretty scary because I'm writing
> > > a lot of code for a geo app that's based on that property of
> > > geohashes, described athttp://labs.metacarta.com/blog/27.entry/,
> > > working. I knew about equator, etc cases needed special handling, but
> > > I'm not too concerned.
>
> > > -U
>
> > > On Sep 3, 10:23 pm, Pierre <[EMAIL PROTECTED]> wrote:
>
> > > > Hi,
>
> > > > I need to find points (lat/lng) within a certain bounding box. To do
> > > > so, I tried Geohash python implementation (http://mappinghacks.com/
> > > > code/geohash.py.txt).
>
> > > > Problem's data is :
> > > > - I have 2 points (South west SW corner / North east NE corner)
> > > > describing a geographic Bounding box
> > > > - I have a model (let's call it 'Poi') having a field "geohash" of
> > > > type Db.StringProperty + Lat and Lng field (Float)
>
> > > > Question is : How on earth (lol :-) ) can I find all Poi within my
> > > > bounding box ?
>
> > > > I've already tried something like :
>
> > > > Create Geohash for SW, create Geohash for NE and do something like :
>
> > > > "SELECT * FROM Poi WHERE geohash >:1 and geohash <= :2, geohash(SW),
> > > > geohash(NE)"
>
> > > > Also tried with geoindex, at different depth but all this fails and
> > > > still give points not located within Bounding box.
> > > > Also tried like describe in "http://labs.metacarta.com/blog/27.entry/
> > > > geographic-queries-on-google-app-engine/" to create a small
> > > > surrounding box for each Poi and then create a geohash for this
> > > > specific bounding box to be in between my SW->NE bounding box....
>
> > > > Nothing is working even with "not worst case" (I mean equatorial
> > > > problem...) case/
>
> > > > Any help will be greatly appreciated.
>
> > > > Thanks all,
>
> > > > Pierre
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to