GeoTransformer 4.1

by Knaģis 12. April 2012 03:33

GeoTransformer 4.1 is now available. Download, issue tracker, discussions and documentation is now available at CodePlex.

Release notes:

  • Added an option to put geocache attributes in a log entry so it can be read on GPS.
  • Added an option to select which caches should be ignored when publishing.
  • Inner workings of GeoTransformer changed to strongly-typed objects which mean better performance and support for GPX 1.1 files. Partial support for Groundspeak 1.0.2 extensions is also implemented (this version is still under development by Groundspeak and not yet available for geocaching.com users).
  • Virtual caches are now displayed on the map with the correct symbol.
  • Geocache list tables now remember sort, column widths and hidden columns.
  • List view / editor size proportion is now saved between restarts.

Tags: ,

Geocaching

Memory and performance of .NET dictionaries

by Knaģis 29. March 2012 19:12

Since generics were added to .NET everybody seems to have forgotten about all the different dictionaries available in the framework and uses Dictionary<,>. I was doing the same until recently I ran into a situation where tens of thousands of dictionaries are created and the memory usage went rather high.

In my case most of the dictionaries are rather small (mostly 2-3 items) so the first thing I tried was switching to HybridDictionary. A short test later I found out that by performing this simple switch I have reduced the memory usage by 10%.

So I went to investigate and compare the various dictionaries available in .NET both of the previously mentioned and also Hashtable, ListDictionary, OrderedDictionary, SortedDictionary, SortedList.

The test is very simple – it recursively creates dictionaries (with integers as keys) and captures both memory usage and time it took to create the dictionary and fully read it (once). Of course, each of the abovementioned classes have their specific usages, especially the sorted and ordered ones but this test only looks at a simple un-optimized scenario.

image

The first test creates small dictionaries in 9 levels (each dictionary contains 5 other dictionaries). What the results show is that HybridDictionary (together with ListDictionary that is used by it internally) takes the lead with much better timings and memory usage than the standard Dictionary<,>.

image

As expected, raising the size of each dictionary put ListDictionary in a bad position. Why SortedList with typed key has surprisingly good memory/performance ratings - it uses a simple array for storage and the test uses sequential keys that is the strong point for this class. A bit strange is the bad performance of Hashtable (memory-wise) especially since Hashtable is the class being used by HybridDictionary in this case and it does not show this weakness. It is not because of cold start as the tests were run multiple times and always produced the same result.

Obviously this needs more research and probably better ways of measuring the memory consumption (I am using GC.GetTotalMemory method) but it should be enough to remind that performance is not the only thing to measure when using lots of collections – there is a lot of memory overhead that should be investigated to find the best possible match for each scenario.

Another thing to mention is that the dictionaries increase their capacity in bulk so even if the dictionary size is 200 the capacity of the underlying data stores could as well be 300. It might seem to be a good idea to set the capacity with the appropriate constructor (as long as the maximum is known beforehand) but couple of quick tests showed that for Dictionary<,> it might produce even worse results. Although this again could be the result of suboptimal testing techniques.

Source code for the test application.

More results on different dictionary sizes.

Tags:

Programmēšana

GeoTransformer goes open source

by Knaģis 7. March 2012 12:23

GeoTransformer is now available at CodePlex as a open source project. This is not one those situations where “going open source” means “I’m out, if someone else wants, here”. In this case I really think that giving full access to the source code and moving to a solid platform for project maintenance will benefit the application.

The new website: http://geotransformer.codeplex.com/

What new features this move brings to the table:

  • The source code is available to everyone under Ms-RL license (in short it means that you are free to use it in any project but you have to keep the copyright headers intact).
  • Wiki based documentation (currently it is still empty but it will come there).
  • Discussions section (forum).
  • Issue tracker – place to submit bugs and feature requests.

If there is someone who wants to join the development or help write the documentation, please send me a note.

Tags: , ,

Geocaching | Programmēšana

Visual Studio 11 Beta

by Knaģis 1. March 2012 16:57

No šodienas lejupielādei un eksperimentiem ir pieejama Visual Studio 11 un TFS 11 Beta versijas.

Neliels brīdinājums – .NET Framework 4.5 ir update 4.0 versijai (kā 3.5 pret 2.0), nevis atsevišķa versija, līdz ar to Beta instalācija (jebkura produkta, jo tiem visiem vajag .NET Framework jauno) ietekmēs visas esošās aplikācijas un Visual Studio 2010. Diemžēl uz savas ādas pārbaudīju, ka izmaiņas nav tik perfekti atpakaļsavietojamas, kā gribētos (manā konkrētā gadījumā uzrāvos uz WCF servisiem). Esošā aplikācija pēkšņi ar ļoti dīvainu kļūdu sāka nestrādāt.

Kas vēl jautri – palaižot uninstall uz 4.5 Beta, tiek atinstalēts arī viss .NET Framework 4.0…

Tags: , ,

Programmēšana

GeoTransformer 4.0

by Knaģis 27. February 2012 11:28

Layers-iconDownload GeoTransformer.zip (1.21 Mb)

A new version of GeoTransformer is now available. As usual, existing installations will update automatically.

The biggest change is the introduction of geocaching.com Live API. This means that there is a new search functionality directly in the application. Unfortunately pocket queries are still the way to go because the direct search is rather slow. There are only two benefits from the direct search – it allows filter by favorite points and it enables basic members to download cache names and coordinates (no descriptions and hints though).

Other changes:

  • First run now displays a welcome screen that should help new users to start using GeoTransformer – existing users should complete it as it includes logging into Live API and it is now required for pocket query download.
  • Additional waypoints will automatically be enhanced:
    • The description on the GPS unit will now display the name of the waypoint (that was previously not visible at all) and the name of the cache that the waypoint belongs to.
    • Trail head waypoints will now have the correct symbol (image on Garmin).
    • All other waypoints will now have a random color navaid (circle) symbol. This will allow you to visually group waypoints for a single cache. The color of waypoints are chosen from the cache code so it always remains the same.
  • Bing Maps view now displays disabled caches as grayed out icons. It also displays the name of the cache when the mouse hovers over the icon.
  • Various bug fixes, for example, now it is possible to move the GeoTransformer data file around without the application crashing.

Custom waypoint symbolsCustom waypoint symbolsMap viewDirect search queries

Tags: ,

Geocaching

Satelītkartes kā ekrāntapetes

by Knaģis 9. February 2012 16:28

Tīri nejauši uzgāju jauku piedāvājumu no Microsoft – Windows 7 dinamiskā ekrāntapete, kas attēlo labākos skatus no Bing Maps satelītkartēm.

Viens klikšķis uz Download, tad Run un turpmāk ekrāntapete attēlos skaistus foto no gaisa.

Bing Maps Aerial Imagery theme: Europe

Tags: , ,

Internets | Windows 7

LĢIA kartes priekš OziExplorer

by Knaģis 9. January 2012 12:32

Lielākā daļa no tiem, kam hobijs vai darbs saistās ar kartēm (pat jā tā ir tikai slēpņošana vai 4x4 bezceļu orientēšanās) programmatūras meklējumos agri vai vēlu nonāk līdz OziExplorer. Iemesli ir dažādi, bet tieši šo programmatūru daudzi atzīst par vislabāko, ja vajag strādāt ar rastra kartēm.

Taču pati programmatūra ir tikai tik vērtīga, cik labas ir pieejamās kartes. Pietiekami ilgi apgrozoties noteiktās aprindās, tiks iegūti kontakti, kuri padalīsies ar dažādām jaunām un vecām kartēm, ja tādu nav, var pats skenēt un kalibrēt kartes vai arī iztikt ar publiski pieejamiem risinājumiem, piemēram Google Maps.

Taču Google Maps Latvijā pat zemes lielceļi daļa nav sazīmēti un tipiskajai lietošanai derīgas ir tikai satelītkartes. No pieejamajām alternatīvām (kurtuesi, balticmaps.eu utt.) vislabākās kartes viennozīmīgi ir LĢIA karšu serverī. Lielajos mērogos tās nav tik ērtas un pārskatāmas kā citas, taču informācija tajās ir vispilnīgākā.

Iepriekš pieminētajās aprindās jau kādu laiku no rokas rokā ir klīdusi manis izstrādāta programmiņa, kas ļauj LĢIA kartes lejupielādēt un konvertēt izmantošanai OziExplorer. Tagad piedāvāju to lejupielādēt ikvienam, kam ir nepieciešamas labas Latvijas kartes OziExplorer (vai arī jebkurā citā kartēšanas aplikācijā, jo gandrīz visas ļauj importēt OziExplorer karšu formātu).

Lejupielādēt Lgia2Ozi. Pirms palaišanas vajadzēs atvērt .config datni un ievadīt direktorijas, kurās saglabāt kartes datus.

Jāņem vērā, ka vajag prātīgi izvēlēties, kurus apgabalus lejupielādēt. Piemēram, nav jēgas mēģināt “Riga Topo” līmenī iezīmēt Liepāju, jebkurā līmenī iezīmēt sektorus jūras vidū vai “V4 Aero” iezīmēt Latgali (šajā fotogrāfēšanas kārtā nosegta ir tika rietumu daļa, sīkāk var palasīt LĢIA lapā).

Tāpat lūdzu atcerēties, ka uz kartēm attiecas autortiesības. Visās ģenerētajās kartēs ir prasītā atsauce uz informācijas autoru, taču, lūdzu, noskaidrojiet juridiskās nianses, ja kartes plānojat izmantot ne tikai savām personiskajām vajadzībām.

image

Tags: ,

Geocaching

Fotoradari strādā

by Knaģis 6. January 2012 11:32

Fotoradari tiešām strādā – šodien saņēmu e-pastu par savu pirmo grūtā darbā nopelnīto sodu 10 latu vērtībā. Pārkāpuma datums 20. decembris, protokols sastādīts 4. janvārī, e-pasts nosūtīts 6. janvārī.

Tā kā esmu reģistrējies e.csdd.lv, man par šo faktu tika paziņots e-pastā, aizejot uz CSDD lapu, pie transportlīdzekļa datiem var atrast faktu par neapmaksāto sodu, kuram pievienots PDF fails ar visu aprakstu. Mani noķēra Rīgā ar 72km/h, radara kļūda 3km/h, rezultātā 69km/h.

Interesanti, ka pievienotajā bildē viss priekšējais stikls ir aizkrāsots – nav iespējams noteikt, kas ir pie stūres.

fotoradars

Tags:

Dažādi

Advanced Format cietie diski

by Knaģis 28. December 2011 12:27

Pavisam nemanāmi cieto disku ražotāji ir spēruši nelielu soli uz priekšu un šobrīd ražo diskus ar 4kB sektora izmēru (ieprieš bija 512 baiti) – un tos gudri nosaukuši par Advanced Format diskiem. Pa lielam tas jāņem vērā tikai tiem, kas izmanto vecās operētājsistēmas (piemēram, Windows XP), jo tad var būt nepieciešamība palaist speciālu programmu, kas optimizē veiktspēju. Bet visiem pārējiem šī izmaiņa neko neietekmēs ikdienas dzīvē.

Izņemot – ja vēlēsieties savienot RAID masīvā vecā tipa disku ar jauno formātu. Es gan esmu mēģinājis tikai Windows Server iebūvēto software RAID, bet pieņemu, ka arī hardware risinājumi paziņos to pašu – neatbilstošu sektoru izmēru dēļ diskus nav iespējams apvienot vienā masīvā.

Tags:

Datortehnika

GeoTransformer 3.1

by Knaģis 10. November 2011 00:27

Layers-iconDownload GeoTransformer.zip (1.29 Mb)

A new version of GeoTransformer is now available. Starting from version 3.0 the application supports third party extensions (description on how to develop them will follow) and also by default contains much more functionality, such as the Bing map view.

Also version 3.1 contains an important fix for the Bing translator that restores its functionality to GeoTransformer.

Note: if your version automatically upgraded to version 3.0 few weeks ago then you will not get automatic update to this or any future version because of a bug in that particular version. Please update manually.

image

Tags: ,

Geocaching

RecentComments

Comment RSS