Description Usage Arguments Value Examples
Probe to see whether the Keras python package is available in the current system environment.
1 |
version |
Minimum required version of Keras (defaults to |
Logical indicating whether Keras (or the specified minimum version of Keras) is available.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | ## Not run:
# testthat utilty for skipping tests when Keras isn't available
skip_if_no_keras <- function(version = NULL) {
if (!is_keras_available(version))
skip("Required keras version not available for testing")
}
# use the function within a test
test_that("keras function works correctly", {
skip_if_no_keras()
# test code here
})
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.