Skip to content

image_to_mosaic with dithering return error #34

@kevin-netsrik

Description

@kevin-netsrik

R return error when dithering is TRUE, maybe is R version issue?

demo_img = file.path(getwd(),'test.png')
mosaic1 <- png::readPNG(demo_img) %>% image_to_mosaic(img_size = 48, dithering = TRUE)
Error: Assigned data `as.character(...)` must be compatible with row subscript `mosaic_base$x == xx & mosaic_base$y == yy`.
✖ 1 row must be assigned.
✖ Assigned data has 2 rows.
ℹ Row updates require a list value. Do you need `list()` or `as.list()`?
Backtrace:
     █
  1. └─`%>%`(...)
  2.   ├─base::withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  3.   └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
  4.     └─base::eval(quote(`_fseq`(`_lhs`)), env, env)
  5.       └─`_fseq`(`_lhs`)
  6.         └─magrittr::freduce(value, `_function_list`)
  7.           ├─base::withVisible(function_list[[k]](value))
  8.           └─function_list[[k]](value)
  9.             └─brickr::image_to_mosaic(...)
 10.               └─`%>%`(...)
 11.                 ├─base::withVisible(eval(quote(`_fseq`(`
Execution halted
$ R --version
R version 4.0.0 (2020-04-24) -- "Arbor Day"
Copyright (C) 2020 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin17.0 (64-bit)

Metadata

Metadata

Assignees

No one assigned

    Labels

    brickr mosaicsIssues related to mosaicsbugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions