GenoPro Home
GenoPro Home  |  Get Started With My Genealogy Tree  |  Buy  |  Login  |  Privacy  |  Search  |  Site Map
 

GenoPro Support Forum




Geocoder for GenoPro

Click to view RSS...
Author A browser-based Javascript app to add location coordinates to Place records in your .gno file
Posted Monday, March 20, 2017 - Post #37768
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 3,424, Visits: 26,491
Ok, still a few issues, but then I did say 'experimental' in my topic description Ermm

I made some changes in one of the interim releases that has caused the problems you describe. I can fix that.  What my code tried to do is decide whether the place name or address ends with country name, because if it doesn't I want to use the default country code to restrict Google's search.  A bug in my code means this is not working correctly. I take the last part of a place name (following the last comma, or whole name if no commas) and compare it with a list of countries. The problem was I was not stripping leading and trailing spaces before the comparison. Also when concatenating hierarchic place names, I was not adding a separating comma.

The approach of comparing place names has serious limitations as my country name list is severely restricted in the languages covered (i.e. just the official language of each Country and in some cases English). I think I will have to make the default option to be not to have a default country. Another solution might be to use the internationally recognized country codes.

Your place name 'Brixton, Surrey' with country U.K. is an interesting one. Brixton, Surrey is an historical address, as Brixton is now in the London Borough of Lambeth, and not the county of Surrey. Also, my code does not currently recognize 'U.K.' as a country, but UK or United Kingdom would be. 

But not withstanding that, there is still a problem. I use EITHER the (hierarchic) place name OR the postal address, if present, as the address to be geocoded. This did not include a mixture of the two. I have fudged such that if the only address component present is the country and the place category is not 'Country' then the Country field value is appended to the place name before geocoding.

Actually if 'U.K.' is appended to the place name giving 'Brixton, Surrey, U.K.' Google still does not find the correct place, but gives the centre of Surrey. However if 'City' is set to Brixton and County/Region set to Lambeth the correct place is found. The solution to handle non-current historical place names I think is to set the postal address fields to the current address.

I have attached another reincarnation of this 'app', that fixes the issues described in para 2 above and adds a 'Hide Marker' button so that after visual verification you can de-clutter the map. Also renamed Halt button to Pause and some other bits and pieces to improve messages.

If I get time I will look at adding a form to allow changing of place names, address fields and categories.  This will allow issues with geocoding to be resolved within the 'app' without the need to amend these details in GenoPro.


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


Edited: Friday, March 31, 2017 by genome
Posted Tuesday, March 21, 2017 - Post #37769
Grand Master

Grand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand Master

Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 1,585, Visits: 31,897
Had a quick look and only one comment so far. Tried to click Index.htm and it part started but stuck on initial screen without ability to do anything  (I know you said use File Open) Copied the files from the shared folder into js and seems to start properly then. Thought for final distribution.
Gardening calls so will look again later.
Point about spaces around names. I have often thought it would be useful if GenoPro removed these. I noticed in the list of names there appear to be duplicates which are caused by extra space at the end. Use of copy/paste can easily lead to these and it is not initially obvious.
Option for GenoProX?


Edited: Tuesday, March 21, 2017 by appleshaw
Posted Tuesday, March 21, 2017 - Post #37772
Grand Master

Grand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand Master

Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 1,585, Visits: 31,897
Tried a few more and only one very obvious mis-match of Middlesex, U.K. over the town of Middlesex in New York state. This had a yellow marker, so not convinced it was correct.
Seems to think that Woolwich, Kent is north of the river.
Generally near enough but need checking eg Parish Church, Croydon was identified as the Catholic church. Zooming in on Church Street did not see the old church, so just shows that it is necessary to check locations, and clearing the display after confirmation is a useful feature.
Had not realised that the map cane be zoomed with the mouse wheel. Life is always full of surprises and some of them are nice.


Edited: Tuesday, March 21, 2017 by appleshaw
Posted Wednesday, March 22, 2017 - Post #37773
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 3,424, Visits: 26,491
Thanks for testing further. I am working on the enhancement to allow editing of place name, address, category and parent. 

 I have also found a few of bugs that I will correct.  Firstly if you hide a marker then that place's location coordinates are not saved in the .gno (as I was relying on the marker position for the values). Secondly if existing coords in the .gno are invalid e.g. not a valid number, then this can cause Google Maps API to loop and eventually crash. You will notice a slow down. If the existing coordinates are not in signed decimal format (e.g. as degrees, minutes and seconds NESW)  they also cause issues. I wrote a conversion function for this but forgot to use it!

Sometimes clicking the box for the open file window does nothing.  I believe that Google Maps is hanging on to the mouse click event and my code doesn't see it. Unsure as to the solution to this at present but often clicking the map first and then the box works, and sometimes multiple clicks on the box kick starts it too.


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"
Posted Wednesday, March 22, 2017 - Post #37774
Grand Master

Grand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand Master

Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 1,585, Visits: 31,897
If the hidden data are not saved I will await next version.
It has proved a useful error spotter. Grimsby, Turkey? This had me puzzled as editing of place Grimsby showed no parent place. Took me some time to spot Turkey had been added as Country. Don't ask me how or why. Only link is that he had fought at Gallipoli but the record related to his death.
Posted Friday, March 31, 2017 - Post #37801
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 3,424, Visits: 26,491
Well it has been a while but I think the next iteration is ready.  I have added code to allow changes to place name, address, category and parent place. This gives the ability to adjust details so that Google gets the correct location rather than having to manually move the marker  to its correct place.  Hidden markers for new/changed geocodings are now saved if .gno downloaded.

It hasn't been exhaustively tested but at present I am exhausted from testing!  So the usual caveats apply - don't overwrite your precious .gno, save to another file and check results please.  This software is offered 'as is' without any warranty or guarantee, users do so at their own risk.

If you find any problems or have further suggestions then respond here.


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


Geocode3.zip (10 views, 57.21 KB)
Posted Saturday, April 1, 2017 - Post #37803
Grand Master

Grand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand MasterGrand Master

Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 1,585, Visits: 31,897
Tried to edit a place (first in file) but could not get out of edit menu. Tried adding some data but neither the cancel or Ok moved on.
Nothing to do with Geocoder but have you any thoughts on tracking down, within GenoPro, the link between Place and the person containing the reference? At present I am using a text editor to search the xml file but suspect that I have overlooked the obvious.
The need for this is that many place names I have used are copy/pasted from census etc and in many cases it is a street address without town. (This could be another item for Problem Spotter, although it would not be simple, although query where address does not have a parent would be a start - as long as it could be excluded from check)
Back to gardening
Posted Saturday, April 1, 2017 - Post #37806
Legendary Master

Legendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary MasterLegendary Master

Administrators
Customers
Important Contributors
FamilyTrees.GenoPro.com
GenoPro version: 3.1.0.1

Last Login: 6 hours ago
Posts: 3,424, Visits: 26,491
Most of my testing is with Chrome and it appears that FireFox handles events differently, so at the moment those buttons only work in Chrome. 

The attached version fixes it for Firefox.

Yes, you could be overlooking the obvious when it comes to finding references to places.  Just use the References tab of the Place Properties dialogue.


'lego audio video erro ergo disco' or "I read, I listen, I watch, I make mistakes, therefore I learn"


Geocode3.zip (18 views, 57.47 KB)

Edited: Saturday, April 1, 2017 by genome


Similar Topics

Click to view RSS...
Expand / Collapse

Reading This Topic

Expand / Collapse
Active: 3 - 1 guest, 1 member, 0 anonymous.
Refresh