Author Topic: New HB findroute implementation  (Read 11823 times)

0 Members and 1 Guest are viewing this topic.

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #15 on: June 29, 2020, 05:00:50 pm »
Yes, 60000-line HTML tables are memory hogs.

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #16 on: July 01, 2020, 03:58:47 pm »
Several of the suggestions upthread and a few other ideas have made their way in.  Now on tmtest there is also a link from the main HB landing page to findroute.  Existing functionality was not impacted (intentionally).

I'll be putting this live on the main site soon.  I will continue to seek efficiency improvements and would be happy to hear further functionality suggestions, and of course would like to know about any bugs.  But I don't see any need to keep the new functionality hidden away only on tmtest.

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #17 on: July 01, 2020, 04:25:44 pm »
https://tmtest.teresco.org/hb/

Quote
Fatal error: Uncaught Error: Call to undefined function tm_dismiss_button() in /home/www/tmtest/hb/index.php:117 Stack trace: #0 {main} thrown in /home/www/tmtest/hb/index.php on line 117

https://tmtest.teresco.org/hb/findroute.php

Quote
Fatal error: Uncaught Error: Call to undefined function tm_dismiss_button() in /home/www/tmtest/hb/findroute.php:100 Stack trace: #0 {main} thrown in /home/www/tmtest/hb/findroute.php on line 100

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #18 on: July 01, 2020, 05:08:07 pm »
Sorry about that - I was looking into the mapview bug I just commented on over in GitHub, and I clobbered the new HB functionality on tmtest!  Should be back in a few minutes.

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #19 on: July 02, 2020, 10:47:38 am »
The Route Finder is now up on the main site.

I'm going to open some GitHub Issues for ideas and problems that have been brought up in this thread.  Please continue to send along suggestions and problem reports here or in Issues.

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #20 on: July 02, 2020, 12:46:40 pm »
Several of the suggestions upthread and a few other ideas have made their way in.

I could finally test it. Great work :)

I've opened Github issues for my remaining suggestions. List of all open findroute issues:
https://github.com/TravelMapping/Web/issues?q=is%3Aopen+is%3Aissue+label%3Afindroute

The in progess or loading message is important to me and likely not rocket science.

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #21 on: July 02, 2020, 01:25:41 pm »
I just changed the ordering of routes within the table to be CSV order.  This results in each system appearing in the order it appears in systems.csv, and routes within each system appearing in the order in which they appear in that system's chopped routes .csv file.

I thought about trying to go for some sorting, but I think this page needs to focus on filtering.

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #22 on: July 02, 2020, 02:12:38 pm »
I thought about trying to go for some sorting, but I think this page needs to focus on filtering.

I had already submitted an issue just a few minutes earlier ;)

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #23 on: July 02, 2020, 05:43:08 pm »
Now on tmtest, an experiment with findroute to try to speed up filtering.  Instead of building the whole table and using each row's display property to show or hide it, I just rebuild the whole body of the table each time.  On my browsers, it seems to speed things up somewhat when lots of routes are displayed (no or very limited filtering), and speeds things up a lot when fewer routes are displayed (more restrictive filters).

See what you think, but I'll probably make this the production version very soon.

Offline Jim

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 2732
  • Last Login:Today at 02:09:10 pm
Re: New HB findroute implementation
« Reply #24 on: July 02, 2020, 06:12:02 pm »
Now on tmtest, an experiment with findroute to try to speed up filtering.

Again, I'm interested to hear what people are seeing in various situations.  It seems things fast or slow for the browsers I'm testing with are not necessarily consistent with what others see.

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #25 on: July 03, 2020, 06:25:39 am »
Wow! Huge improvement!

17 seconds on my notebook, 15 seconds on my smart phone. Initial load.

The initial load is 7..8 seconds on my notebook now!
And when I filter, it's almost prompt (maximum 1-3 seconds), e.g. when I apply the tier filter!

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #26 on: July 05, 2020, 02:11:41 am »
Available on the main site now: https://travelmapping.net/hb/findroute.php

Offline yakra

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4234
  • Last Login:February 13, 2024, 07:19:36 pm
  • I like C++
Re: New HB findroute implementation
« Reply #27 on: July 05, 2020, 06:02:18 pm »
Down to just under 7s on BiggaTomato now.
Sri Syadasti Syadavaktavya Syadasti Syannasti Syadasti Cavaktavyasca Syadasti Syannasti Syadavatavyasca Syadasti Syannasti Syadavaktavyasca

Offline vdeane

  • Sr. Member
  • ****
  • Posts: 387
  • Gender: Female
  • Last Login:Yesterday at 09:23:42 pm
    • New York State Roads
Re: New HB findroute implementation
« Reply #28 on: July 25, 2020, 06:42:14 pm »
Question: do we want the only links to this page to be from notifications with a "dismiss" button?  Especially since it always reappears on reload... seems to me that we could probably get rid of the "dismiss" button.
Please note: All comments here represent my own personal opinion and do not reflect the official position of NYSDOT or its affiliates.

Offline michih

  • TM Collaborator
  • Hero Member
  • *****
  • Posts: 4555
  • Last Login:Today at 04:44:01 pm
Re: New HB findroute implementation
« Reply #29 on: September 25, 2020, 01:09:16 pm »
I don't know whether the mechanism is just route-based. If not....

A simple "Don't show routes" check box (default = true) would make the trick... ;)

...could this reduce loading times? Maybe the table could be generated without routes and routes are just loaded in the background. If one disables "Don't show routes" they might already be loaded.

Just my 2c. Just an idea..........

Putting hb/index.php in CSV order would be better. Or maybe fixing Findroute to let users filter by region, system, etc. before it loads every route in the TM database, which creates delays that for me makes Findroute unusable. That fix might also allow us to decommission hb/index.php.

Is it feasible and worth to open a Github issue?