Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Export reactlog #37

Open
leedrake5 opened this issue May 1, 2019 · 6 comments
Open

Export reactlog #37

leedrake5 opened this issue May 1, 2019 · 6 comments

Comments

@leedrake5
Copy link

My shiny app is so large that the reactlog is unresponsive and hangs for several minutes trying to render every step of a zoom - is there a way to save the reactlog and open it in another program? I am more than happy to even parse it by text without any kind of visualization, but I need some way to access it without a web browser. In its current implementation I can neither recover the data nor use it when debugging my app.

@schloerke
Copy link
Collaborator

I'm actually very excited about this bug. We were curious how long it would take to hit an efficiency issue. This is definitely an efficiency issue.

To access the reactlog produced by shiny directly: shiny::reactlog().


Is it ok for you to post your reactlog contents? I can then try to optimize reactlog around this log...

  • whether is a very sparse network (or dense)
  • whether it is a very long recording or large contents in each step (causing the browser to be slow)
  • Maybe the log needs to be pre-pruned before it is sent to the browser

... many different places to optimize.

# save reactlog to FILE.txt
dput(shiny::reactlog(), file = "FILE.txt")

Thank you in advance, @leedrake5 !

@leedrake5
Copy link
Author

Happy to be the first! I did find a computer that can display the output in a browser, but it had to have a graphics card with 16 gb memory (Radeon Vega Pro 64). It failed on a system with a Radeon Vega Pro 20 with 4 Gb. I am assuming it is the graphics card that is the point of failure.

Here is a zoomed out version of what was having such a hard time to render:
IMG_6607

And the reactlog itself:
CloudCalReactLog.txt

Thanks for you and your team's development efforts! I am astounded by how well shiny works for application development and deployment.

@schloerke
Copy link
Collaborator

I can see some slow down on my end, but the progress bar at the top fills in within 10 seconds and the graph displays with 2 more seconds. Clicking to a random location in the progress bar displays an updated graph in ~5 seconds. I'm on MBP; 32GB Ram; 4GB Graphics; Chrome. Which system/browser are you using?

As a consolation, if any filtering is done (search in top right corner), it is very quick to render. Such as search for foresttryui (I'd copy/paste to avoid intermediate searches).

Screen Shot 2019-05-01 at 8 33 20 PM


Maybe it might be useful to have the ability to not do animations for transitions in the graph. I believe this would greatly reduce the computation load on the browser. Makes for a non-optimal user experience, but not being able to see the network in the first place is not optimal..... so Fast/Choppy is better than Waiting.

Thoughts?

@schloerke
Copy link
Collaborator

Notes: Steps to reproduce:

"CloudCalReactLog.txt" %>%
  dget() %>%
  reactlog::reactlog_show()

@leedrake5
Copy link
Author

You are right- it does look like it is browser-dependent. I took a video of how it performs in safari. Not speedy, but still useable. I was using Firefox before, since it is much more stable for loading large file numbers ( x > 10,000) in shiny.

What might help is adding some kind of debounce to text input - it seems to try and redraw the graph with every character input into the text box in the upper write. If a delay in searching was set to the average typist speed of new inputs, it might save some graphics processing on slower laptops.

@ksimonova
Copy link

ksimonova commented Nov 19, 2020

I'm actually very excited about this bug. We were curious how long it would take to hit an efficiency issue. This is definitely an efficiency issue.

To access the reactlog produced by shiny directly: shiny::reactlog().

Is it ok for you to post your reactlog contents? I can then try to optimize reactlog around this log...

  • whether is a very sparse network (or dense)
  • whether it is a very long recording or large contents in each step (causing the browser to be slow)
  • Maybe the log needs to be pre-pruned before it is sent to the browser

... many different places to optimize.

# save reactlog to FILE.txt
dput(shiny::reactlog(), file = "FILE.txt")

Thank you in advance, @leedrake5 !

Loving the package but I cannot seem to do this. How/where is this code meant to be run, @schloerke? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants