Git Product home page Git Product logo

imagefluency's People

Contributors

stm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

imagefluency's Issues

Wrong code in batch-processing vignette

In the Analyzing multiple images at once vignette, there is an error in the code at the Parallel processing with multiple cores part.

Specifically, the code incorrectly uses mclapply() instead of lapply() in the first timed computation:

# compute imgagefluency scores using lapply()
tictoc::tic("lapply")
results_lapply <- pbmcapply::pbmclapply(allImages, img_fluency_scores)
tictoc::toc(log=TRUE)

The third line should compute the scores either using lapply() or pbapply::pblapply() (for a progress bar version of lapply().

Error: Invalid input (should be a matrix or a 3-dimensional array of numeric or integer values)

Hello,

I'm trying to generate the symmetry, self-similarity, and contrast values (simplicity and complexity work fine!), but I'm getting this error: Error: Invalid input (should be a matrix or a 3-dimensional array of numeric or integer values)

It's weird because it's working just fine with simplicity. But there's some error that doesn't allow the other functions to work. Can you help me? Also, the pictures I'm using work on the shiny app. So I suspect it's something with R.

Thanks

Error: Could not find shiny app directory. Try re-installing `imagefluency`.

Thank you for creating this package, Stefan! I stumbled across it, and I hope to detect the existence of handwriting on PDF files with the measure of image complexity. (By the way, the Mayer & Landwehr paper was fascinating!)

I tried to run the package overview function, imagefluency::run_imagefluency(). In doing so, I received the following error message: Error: Could not find shiny app directory. Try re-installing `imagefluency`..

I went into the package installation, and I found the shiny app directory: imageFluencyApp. I was able to run the app.R file with no problems. So, I'm not sure why the directory isn't being recognized. I used the renv package to install imagefluency, but I haven't had any trouble with the img_complexity function.

Here is the output from sessionInfo():

> sessionInfo()
R version 3.5.3 (2019-03-11)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux Server 7.9 (Maipo)

Matrix products: default
BLAS: /opt/R/R-3.5.3/lib64/R/lib/libRblas.so
LAPACK: /opt/R/R-3.5.3/lib64/R/lib/libRlapack.so

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8   
 [6] LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices datasets  utils     methods   base     

other attached packages:
 [1] shiny_1.6.0                  image.textlinedetector_0.1.3 imagefluency_0.2.3           furrr_0.2.2                 
 [5] future_1.21.0                pdftools_2.3.1               strex_1.1.0                  formattable_0.2.1           
 [9] lubridate_1.7.10             easyr_0.5-2                  forcats_0.5.1                stringr_1.4.0               
[13] dplyr_1.0.4                  purrr_0.3.4                  readr_1.4.0                  tidyr_1.1.3                 
[17] tibble_3.1.0                 ggplot2_3.3.3                tidyverse_1.3.0             

loaded via a namespace (and not attached):
 [1] fs_1.5.0          httr_1.4.2        tools_3.5.3       backports_1.1.2   bslib_0.2.4       utf8_1.1.4        R6_2.5.0          DBI_1.1.1        
 [9] colorspace_1.3-2  withr_2.4.1       readbitmap_0.1.5  tidyselect_1.1.0  processx_3.5.1    compiler_3.5.3    cli_2.4.0         rvest_0.3.6      
[17] xml2_1.3.2        sass_0.3.1        scales_1.1.1      askpass_1.1       tiff_0.1-8        digest_0.6.27     R.utils_2.10.1    rmarkdown_2.7    
[25] jpeg_0.1-8.1      pkgconfig_2.0.1   htmltools_0.5.1   parallelly_1.24.0 dbplyr_2.0.0      fastmap_1.1.0     htmlwidgets_1.5.3 rlang_0.4.10     
[33] readxl_1.3.1      rstudioapi_0.13   jquerylib_0.1.3   generics_0.1.0    jsonlite_1.7.2    R.oo_1.24.0       magrittr_2.0.1    Rcpp_1.0.6       
[41] munsell_0.5.0     fansi_0.4.2       R.methodsS3_1.8.1 lifecycle_1.0.0   stringi_1.1.7     yaml_2.2.1        grid_3.5.3        parallel_3.5.3   
[49] listenv_0.8.0     promises_1.2.0.1  crayon_1.4.1      haven_2.3.1       hms_1.0.0         magick_2.7.1      knitr_1.31        ps_1.6.0         
[57] pillar_1.5.0      codetools_0.2-18  reprex_1.0.0      glue_1.4.2        evaluate_0.14     qpdf_1.1          bmp_0.3           renv_0.13.2      
[65] modelr_0.1.8      png_0.1-7         vctrs_0.3.6       httpuv_1.5.5      cellranger_1.1.0  gtable_0.2.0      assertthat_0.2.1  cachem_1.0.1     
[73] xfun_0.20         mime_0.5          xtable_1.8-2      broom_0.7.4       later_1.1.0.1     globals_0.14.0    ellipsis_0.3.1 

Please let me know if anything else would be helpful.

Symmetry values differ based on the color of the image

When testing out the img_symmetry function, I noticed that the symmetry values change depending on the colors of the image (same when the different colored images are converted to grayscale). Is there a way to enforce exact matches based on color, so that the relative colors don't influence the score?

The 5% shift is also great, though I wonder if it would also be useful to be able to rotate the axis of symmetry, such that one would get a line that is most symmetrical for the image (e.g. if a dominant feature in the image is tilted to the left, it would fit a line to that symmetry, and give a score for the symmetry along that line).

imagefluency package is not working

Hello everyone,

I downloaded imagefluency package to analyze my images in Rstudio. I wrote code, added my images to example_images file. But code is not working. I dont even get any error message from code. Can you help me about this situation?

library(imagefluency)

Get complexity, contrast, simplicity and self similarity values of multiple images in a given folder (all images should be loaded in the "example_images" folder)

imglist <- list("high_1.jpg", "high_2.jpg.jpg", "high_3.jpg", "high_4.jpg.jpg", "high_5.jpg.jpg", "high_6.jpg.jpg")

for (i in imglist) {

i <- img_read(system.file("example_images", i, package = "imagefluency"))

print(data.frame(img_complexity(i),img_contrast(i), mean(rgb2gray(i)), img_self_similarity(i)))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.