Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
^.*\.Rproj$
^\.Rproj\.user$
.travis.yml
README.md
.crancompress
vignettes/rsconnect
rsconnect
^src/libprofit/src/.*\.o$
^.appveyor\.yml$
55 changes: 0 additions & 55 deletions .appveyor.yml

This file was deleted.

85 changes: 85 additions & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
#
# GitHub Actions CI configuration file
#
# ICRAR - International Centre for Radio Astronomy Research
# (c) UWA - The University of Western Australia, 2016
# Copyright by UWA (in the framework of the ICRAR)
# All rights reserved
#
# Contributed by Rodrigo Tobar
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
# MA 02111-1307 USA
#

on:
push:
branches: [master]
pull_request:
branches: [master]

name: R-CMD-check

jobs:
R-CMD-check:
runs-on: ${{ matrix.config.os }}

name: ${{ matrix.config.os }} (${{ matrix.config.r }})

strategy:
fail-fast: false
matrix:
config:
- {os: ubuntu-latest, r: 'oldrel-1'}
- {os: ubuntu-latest, r: 'release'}
- {os: ubuntu-latest, r: 'devel', http-user-agent: 'release'}
- {os: macos-latest, r: 'release'}
- {os: windows-latest, r: 'release'}

permissions:
contents: read

env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
http-user-agent: ${{ matrix.config.http-user-agent }}
use-public-rspm: true

- name: Install system dependencies (Linux)
if: runner.os == 'Linux'
run: sudo apt-get install -y libfftw3-dev

- name: Install system dependencies (macOS)
if: runner.os == 'macOS'
run: brew install fftw

- uses: r-lib/actions/setup-r-dependencies@v2
with:
dependencies: '"hard"'
extra-packages: any::rcmdcheck, any::knitr, any::rmarkdown
needs: check

- uses: r-lib/actions/check-r-package@v2
with:
upload-snapshots: true
76 changes: 0 additions & 76 deletions .travis.yml

This file was deleted.

5 changes: 5 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,8 @@ Depends: R (>= 3.0), Rfits (>= 1.8.0), magicaxis (>= 2.0.3)
Imports: cubature, RColorBrewer, LaplacesDemon, methods, celestial (>= 1.4.1), checkmate
Suggests: fftw, knitr, rmarkdown, ProFound (>= 1.15.0), sn, Highlander (>= 0.1.7), ProSpect
VignetteBuilder: knitr
Remotes:
asgr/Rfits,
asgr/magicaxis,
asgr/celestial,
asgr/ProFound
2 changes: 2 additions & 0 deletions man/profitConvolvePSF.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ Aaron Robotham & Dan Taranu
\code{\link{profitBruteConv}}, \code{\link{profitMakePointSource}}, \code{\link{profitBenchmarkConv}}
}
\examples{
\dontrun{
model = list(
sersic = list(
xcen = c(180, 60),
Expand Down Expand Up @@ -83,6 +84,7 @@ magimage(profitConvolvePSF(model.image, psf, options=list(method='Bruteconv')))
magimage(profitConvolvePSF(model.image, psf, options=list(method='FFTconv', fft=temp$fft)))
magimage(profitConvolvePSF(model.image, psf, options=list(method='FFTWconv', fft=temp$fft)))
}
}
% Add one or more standard keywords, see file 'KEYWORDS' in the
% R documentation directory.
\concept{ PSF}
Expand Down
2 changes: 2 additions & 0 deletions man/profitGetOpenCLEnvs.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,12 @@ Dan Taranu
\code{\link{profitBenchmark}}, \code{\link{profitMakeConvolver}}, \code{\link{profitOpenCLEnv}}
}
\examples{
\dontrun{
envs = profitGetOpenCLEnvs(make.envs=FALSE)
print(envs)
str(envs)
}
}
% Add one or more standard keywords, see file 'KEYWORDS' in the
% R documentation directory.
\concept{ GPU }
Expand Down
2 changes: 2 additions & 0 deletions man/profitHasOpenCL.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,12 @@ Rodrigo Tobar & Aaron Robotham
\code{\link{profitOpenCLEnv}}, \code{\link{profitOpenCLEnvInfo}}
}
\examples{
\dontrun{
profitHasOpenMP()
profitHasOpenCL()
profitHasFFTW()
}
}
% Add one or more standard keywords, see file 'KEYWORDS' in the
% R documentation directory.
\keyword{ OpenMP }% use one of RShowDoc("KEYWORDS")
Expand Down
2 changes: 1 addition & 1 deletion man/profitOpenCLEnv.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ magimage(profitMakeModel(modellist=modellist, dim=c(200,200)))

\dontrun{
profitClearCache()
tempCL=profitOpenCLEnv()
tempCL = profitOpenCLEnv()
magimage(profitMakeModel(modellist=modellist, dim=c(200,200), openclenv=tempCL))
}
}
Expand Down
2 changes: 2 additions & 0 deletions man/profitOpenCLEnvInfo.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,10 @@ Rodrigo Tobar & Aaron Robotham
\code{\link{profitOpenCLEnv}}, \code{\link{profitClearCache}} \code{\link{profitMakeModel}}, \code{\link{profitSetupData}}
}
\examples{
\dontrun{
profitOpenCLEnvInfo()
}
}
% Add one or more standard keywords, see file 'KEYWORDS' in the
% R documentation directory.
\concept{ GPU }% use one of RShowDoc("KEYWORDS")
Expand Down
3 changes: 2 additions & 1 deletion vignettes/ProFit-Make-Model-Image.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ This fine sampling step required manual resampling of the PSF by rescaling re an
We can use `profitMakeModel` to make more complex image structure very easily. The example model below will randomly produce 20 Sersic profiles, 10 PSFs and a sky background:

```{r}
set.seed(666)
model2=list(
sersic=list(
xcen=runif(20,0,200),
Expand All @@ -184,7 +185,7 @@ model2=list(
As before we can run this through `profitMakeModel` and then plot the image. This should run in ~0.5 second, which means we are scaling well with our more complex model:

```{r, fig.width=5, fig.height=5, dpi=40}
system.time(ExampleImagePSF2<-profitMakeModel(modellist=model2, psf=ExamplePSF, dim=c(200,200)))
system.time({ExampleImagePSF2 = profitMakeModel(modellist=model2, psf=ExamplePSF, dim=c(200,200))})
magimage(ExampleImagePSF2, hi=1)
```

Expand Down
Loading