Skip to content

Commit ef0f738

Browse files
committed
comment on profvis
1 parent 44bb6fc commit ef0f738

File tree

2 files changed

+33
-1
lines changed

2 files changed

+33
-1
lines changed

README.Rmd

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,3 +209,15 @@ Profilers identify bottlenecks, but the do not offer solutions. It helps to lear
209209
- <https://www.r-bloggers.com/2016/01/strategies-to-speedup-r-code/>
210210
- <https://www.r-bloggers.com/2013/04/faster-higher-stonger-a-guide-to-speeding-up-r-code-for-busy-people/>
211211
- <https://cran.r-project.org/package=data.table/vignettes/datatable-intro.html>
212+
213+
## What about `profvis`
214+
215+
[`profvis`](https://github.com/r-lib/profvis) is a more widely used and established profiling package, and it existed before `proffer`.
216+
`proffer` was originally developed because:
217+
218+
1. [`profvis`](https://github.com/r-lib/profvis) flame graphs [did not originally support aggregation](https://github.com/r-lib/profvis/issues/115).
219+
2. [`profvis`](https://github.com/r-lib/profvis) visualizations [performed slowly on large profiling datasets](https://github.com/r-lib/profvis/issues/104).
220+
221+
Since then, (1) [has been fixed](https://github.com/r-lib/profvis/pull/126), and it is possible to produce aggregated flame graphs with `print(profvis::provis(...), aggregate = TRUE)`.
222+
When (2) is also addressed, `proffer` may be superseded.
223+

README.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ graph, we see `[<-.data.frame()` (i.e. `x[i, ] <- x[i, ] + 1`) is taking
5454
most of the runtime.
5555

5656
<center>
57+
5758
<a href="https://r-prof.github.io/proffer/reference/figures/flame.png">
5859
<img src="https://r-prof.github.io/proffer/reference/figures/flame.png" alt="top" align="center" style = "border: none; float: center;">
5960
</a>
@@ -74,7 +75,7 @@ system.time({
7475
x <- data.frame(x = x, y = y)
7576
})
7677
#> user system elapsed
77-
#> 0.020 0.001 0.021
78+
#> 0.012 0.000 0.013
7879
```
7980

8081
Moral of the story: before you optimize, throw away your assumptions and
@@ -248,6 +249,25 @@ alternatives to try.
248249
- <https://www.r-bloggers.com/2013/04/faster-higher-stonger-a-guide-to-speeding-up-r-code-for-busy-people/>
249250
- <https://cran.r-project.org/package=data.table/vignettes/datatable-intro.html>
250251

252+
## What about `profvis`
253+
254+
[`profvis`](https://github.com/r-lib/profvis) is a more widely used and
255+
established profiling package, and it existed before `proffer`.
256+
`proffer` was originally developed because:
257+
258+
1. [`profvis`](https://github.com/r-lib/profvis) flame graphs [did not
259+
originally support
260+
aggregation](https://github.com/r-lib/profvis/issues/115).
261+
2. [`profvis`](https://github.com/r-lib/profvis) visualizations
262+
[performed slowly on large profiling
263+
datasets](https://github.com/r-lib/profvis/issues/104).
264+
265+
Since then, (1) [has been
266+
fixed](https://github.com/r-lib/profvis/pull/126), and it is possible to
267+
produce aggregated flame graphs with
268+
`print(profvis::provis(...), aggregate = TRUE)`. When (2) is also
269+
addressed, `proffer` may be superseded.
270+
251271
[^1]: One of the graph visualizations requires Graphviz, which you
252272
<https://www.graphviz.org/download>, but this visualization is
253273
arguably not as useful as the flame graph.

0 commit comments

Comments
 (0)