Skip to content

Commit

Permalink
build for v.1.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
alexmacphail committed Oct 12, 2023
1 parent c87df57 commit f2366ba
Show file tree
Hide file tree
Showing 32 changed files with 149 additions and 76 deletions.
Binary file modified .DS_Store
Binary file not shown.
8 changes: 5 additions & 3 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@

## Major changes

* `wildRtrax` now honours WildTrax report structures. See more here.
* `wildRtrax` now honours new WildTrax report structures. Future changes will incorporate standardized naming in syncing functions.
* Replaced geospatial functionalities from `rgdal`, `rgeos` and `maptools` with `sf`, `sp` and `terra` packages. Added functionality with the `suntools` package. Users should re-download the package by October 2023 in-line with the former package retirement: https://geocompx.org/post/2023/rgdal-retirement/.

## Minor changes

* Tweaks to [Acoustic data wrangling](https://abbiodiversity.github.io/wildRtrax/articles/acoustic-data-wrangling.html).
* Tweaks to [Acoustic data wrangling](https://abbiodiversity.github.io/wildRtrax/articles/acoustic-data-wrangling.html) for (#16)
* Addition of geospatial assets. Users should be warned package size is now ~40 MB.
* Moved TMTT predictions from csv to .RDS.
* Moved TMTT predictions from csv to .RDS file.
* Work flow repairs to `wt_get_species()` and `wt_tidy_species()` (#21)
* Replaced `utils::read.csv()` to `readr::read_csv()` in `wt_download_report()` (#20)

# wildRtrax 1.0.1

Expand Down
19 changes: 6 additions & 13 deletions R/acoustic-pre-processing.R
Original file line number Diff line number Diff line change
Expand Up @@ -351,10 +351,11 @@ wt_run_ap <- function(x = NULL, fp_col = file_path, audio_dir = NULL, output_dir
# Track progress of run
# progressr::with_progress({
# p <- progressr::progressor(steps = nrow(files))
files <- files %>%
files <- files %>>%
"Starting AP run - this may take a while depending on your machine..." %>>%
tibble::as_tibble() %>%
dplyr::rename("file_path" = 1) %>%
furrr::future_map(.x = .$file_path, .f = ~ system2(path_to_ap, sprintf('audio2csv "%s" "Towsey.Acoustic.yml" "%s" "-p"', .x, output_dir)), furrr_options(seed = T))
furrr::future_map(.x = .$file_path, .f = ~ suppressMessages(system2(path_to_ap, sprintf('audio2csv "%s" "Towsey.Acoustic.yml" "%s" "-p"', .x, output_dir)), furrr_options(seed = T)))
# })
return(message('Done!'))

Expand Down Expand Up @@ -401,7 +402,7 @@ wt_glean_ap <- function(x = NULL, input_dir, purpose = c("quality","abiotic","bi
if (dir.exists(input_dir)) {
ind <-
fs::dir_ls(input_dir, regexp = "*.Indices.csv", recurse = T) %>%
map_dfr( ~ read_csv(., progress = F)) %>%
map_dfr( ~ read_csv(., show_col_types = F)) %>%
relocate(c(FileName, ResultMinute)) %>%
select(-c(ResultStartSeconds, SegmentDurationSeconds,RankOrder,ZeroSignal)) %>%
pivot_longer(!c(FileName, ResultMinute),
Expand Down Expand Up @@ -757,9 +758,8 @@ wt_make_aru_tasks <- function(input, output=NULL, task_method = c("1SPM","1SPT",
}
}

#' Upload hits from a Wildlife Acoustics classifier
#' Convert Kaleidoscope output to tags
#'
#' @section `wt_kaleidoscope_tags`
#'
#' @description `wt_kaleidoscope_tags` Takes the classifier output from Wildlife Acoustics Kaleidoscope and converts them into a WildTrax tag template for upload
#'
Expand Down Expand Up @@ -845,7 +845,7 @@ wt_kaleidoscope_tags <- function (input, output, tz, freq_bump = T) {

}

#' Takes the classifier output from Wildlife Acoustics Songscope and converts them into a WildTrax tag template for upload
#' Convert Songscope output to tags
#'
#' @param input Character; The path to the input csv
#' @param output Character; Path where the output file will be stored
Expand All @@ -859,13 +859,6 @@ wt_kaleidoscope_tags <- function (input, output, tz, freq_bump = T) {
#' @import dplyr tidyr readr pipeR stringr lubridate tibble
#' @export
#'
#' @examples
#' \dontrun{
#' wt_songscope_tags(input = input.csv, output = tags.csv,
#' species_code, = "CONI", method = "1SPT",
#' vocalization_type = "Call", task_length = 180)
#' }
#'
#' @return A csv formatted as a WildTrax tag template

wt_songscope_tags <- function (input, output = c("env","csv"),
Expand Down
2 changes: 1 addition & 1 deletion R/wildRtrax.R
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ utils::globalVariables(c("%>>%", ".", "name", "size_Mb", "file_path", "file_ext"
"tag_spectrogram_url",
"task_method",
"wt_spp_table","<<-","clip_type","output_filename","image_date_time",
"unlist", "PC", "sens"))
"unlist", "PC", "sens","organizationId","organizationName"))
17 changes: 8 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

## Installation

You can install version 1.0 of `wildRtrax` directly from this repository with:
You can install version 1.1.0 of `wildRtrax` directly from this repository with:

``` r
# install.packages("remotes")
Expand All @@ -35,12 +35,12 @@ The development version of the package will be periodically merged and will be r
All functions begin with a `wt_*` prefix. Column names and metadata align with the WildTrax infrastructure. The goal is to follow the work flow of pre-processing, linking with WildTrax, download and analysis. Some functions are built specifically for ARUs :sound:, cameras :camera: or point counts :bird:, while others are used for all sensors. :bat: denotes ultrasonic functionalities.
- Pre-process acoustic data
- `wt_audio_scanner()` :sound:
- `wt_audio_scanner()` :sound: :bat:
- `wt_run_ap()` :sound:
- `wt_glean_ap()` :sound:
- `wt_signal_level()` :sound:
- `wt_chop()` :sound:
- `wt_make_aru_tasks()` :sound:
- `wt_chop()` :sound: :bat:
- `wt_make_aru_tasks()` :sound: :bat:
- `wt_songscope_tags()` :sound:
- `wt_kaleidoscope_tags()` :sound: :bat:
- Download data from WildTrax
Expand All @@ -49,15 +49,15 @@ All functions begin with a `wt_*` prefix. Column names and metadata align with t
- `wt_download_report()` :camera: :sound: :bird: :bat:
- Available reports: `main, project, location, recording, image_set, image, tag, point_count, megadetector, megaclassifer, birdnet`
- `wt_get_species()` :camera: :sound: :bird: :bat:
- `wt_download_tags()` :sound:
- `wt_download_tags()` :sound: :bat:
- Analyze data
- `wt_summarise_cam()` :camera:
- `wt_ind_detect()` :camera:
- Convenience functions
- `wt_location_distances()` :sound: :camera: :bird: :bat:
- `wt_tidy_species()` :sound: :camera: :bird: :bat:
- `wt_replace_tmtt()` :sound:
- `wt_make_wide()` :sound: :camera: :bird: :bat:
- `wt_make_wide()` :sound: :bird: :bat:
- `wt_format_occupancy()` :sound: :bird:
- `wt_qpad_offsets()` :sound: :bird:
Expand All @@ -68,12 +68,11 @@ To report bugs, request additional features, or get help using the package, plea
## Contributors
* `wildRtrax` is authored and created by [Alexander G. MacPhail](https://github.com/agmacpha), created and maintained by [Marcus Becker](https://github.com/mabecker89) and created by [Dr. Elly Knight](https://github.com/ecknight). The [Alberta Biodiversity Monitoring Institute](http://https://abmi.ca/home.html) provides ongoing support, development and funding for the package.
* Many thanks to [Dr. Richard Hedley](https://richardwhedley.wordpress.com/) for providing the basis for the `wt_wac_info()` internal function for *wac* file support
* `wildRtrax` is authored, created and maintained by [Alexander G. MacPhail](https://github.com/agmacpha) and [Marcus Becker](https://github.com/mabecker89), with significant contributions from [Dr. Elly Knight](https://github.com/ecknight) and [Dr. Richard Hedley](https://richardwhedley.wordpress.com/). We encourage ongoing contributions and collaborations to improve the package into the future. The [Alberta Biodiversity Monitoring Institute](https://abmi.ca) provides ongoing support, development and funding.
## License
This R package is licensed under [MIT license](https://github.com/ABbiodiversity/wildRtrax/blob/master/LICENSE)© 2023 Marcus Becker, Alex MacPhail, Elly Knight and the [Alberta Biodiversity Monitoring Institute](http://https://abmi.ca/home.html).
This R package is licensed under [MIT license](https://github.com/ABbiodiversity/wildRtrax/blob/master/LICENSE)© 2023 Marcus Becker, Alex MacPhail, Elly Knight and the [Alberta Biodiversity Monitoring Institute](https://abmi.ca).
## Code of Conduct
Expand Down
1 change: 1 addition & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ reference:
- wildRtrax
news:
releases:
- text: wildRtrax 1.1.0
- text: wildRtrax 1.0.1
- text: wildRtrax 1.0.0
- text: wildRtrax 0.1.0
Expand Down
3 changes: 2 additions & 1 deletion docs/404.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/CODE_OF_CONDUCT.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/CONTRIBUTING.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/LICENSE-text.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/LICENSE.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/SUPPORT.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docs/articles/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions docs/authors.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit f2366ba

Please sign in to comment.