Skip to content

Conversation

simonpcouch
Copy link
Contributor

A dplyr::filter() crept into the fit() path. :)

With dev parsnip:

library(parsnip)

bench::mark(fit = fit(linear_reg(), mpg ~ ., mtcars))
#> # A tibble: 1 × 6
#>   expression      min   median `itr/sec` mem_alloc `gc/sec`
#>   <bch:expr> <bch:tm> <bch:tm>     <dbl> <bch:byt>    <dbl>
#> 1 fit          1.51ms   1.78ms      547.    3.76MB     32.5

With this PR:

library(parsnip)

bench::mark(fit = fit(linear_reg(), mpg ~ ., mtcars))
#> # A tibble: 1 × 6
#>   expression      min   median `itr/sec` mem_alloc `gc/sec`
#>   <bch:expr> <bch:tm> <bch:tm>     <dbl> <bch:byt>    <dbl>
#> 1 fit           1.1ms   1.25ms      778.    2.55MB     33.8

Created on 2024-02-26 with reprex v2.1.0

@simonpcouch simonpcouch merged commit 5491946 into main Feb 26, 2024
@simonpcouch simonpcouch deleted the slowdown-form_form branch February 26, 2024 16:48
simonpcouch added a commit that referenced this pull request Feb 26, 2024
Copy link

This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue.

@github-actions github-actions bot locked and limited conversation to collaborators Mar 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant