Skip to content

Commit

Permalink
Merge branch 'release/v2.0.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
CiaranOMara committed Jun 13, 2020
2 parents b99be3f + d63fea9 commit 99632a3
Show file tree
Hide file tree
Showing 22 changed files with 297 additions and 102 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/Benchmark.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Run Benchmarks

on:
- push
- pull_request

jobs:
Benchmark:
runs-on: ubuntu-latest
env:
JULIA_DEBUG: BenchmarkCI
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@latest
with:
version: 1
- name: Install Dependencies
run: julia -e 'using Pkg; pkg"add PkgBenchmark [email protected]"'
- name: Run Benchmarks
run: julia -e "using BenchmarkCI; BenchmarkCI.judge()"
- name: Post Results
if: ${{ github.event_name == 'pull_request'}}
run: julia -e "using BenchmarkCI; BenchmarkCI.postjudge()"
- name: Print Judgement
run: julia -e 'using BenchmarkCI; BenchmarkCI.displayjudgement()'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19 changes: 3 additions & 16 deletions .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Add CompatHelper
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
run: julia --color=yes -e 'using Pkg; Pkg.add("CompatHelper")'
- name: Run CompatHelper
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: julia -e '
using CompatHelper, Pkg;
my_registries = [
Pkg.RegistrySpec(
name = "BioJuliaRegistry",
uuid = "ccbd2cc2-2954-11e9-1ccf-f3e7900901ca",
url = "https://github.com/BioJulia/BioJuliaRegistry.git"
),
Pkg.RegistrySpec(
name = "General",
uuid = "23338594-aafe-5451-b93e-139f81909106",
url = "https://github.com/JuliaRegistries/General.git"
)
];
CompatHelper.main(; registries = my_registries, master_branch = "master");'
COMPATHELPER_PRIV: ${{ secrets.COMPATHELPER_PRIV }}
run: julia --color=yes -e 'using CompatHelper; CompatHelper.main(master_branch = "master")'
14 changes: 6 additions & 8 deletions .github/workflows/Documentation.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Documentation
name: Build Documentation

on:
push:
Expand All @@ -14,14 +14,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@latest
- uses: julia-actions/setup-julia@v1
with:
version: '1.4'
- name: Install dependencies
run: |
julia ci_prep.jl;
julia --color=yes --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
- name: Build and deploy
version: '1'
- name: Install Dependencies
run: julia --color=yes --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
- name: Build and Deploy
env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # For authentication with GitHub Actions token
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} # For authentication with SSH deploy key
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: TagBot
on:
schedule:
- cron: '0 * * * *'
- cron: 0 0 * * *
jobs:
TagBot:
runs-on: ubuntu-latest
Expand All @@ -10,4 +10,3 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
ssh: ${{ secrets.TAGBOT_KEY }}
registry: BioJulia/BioJuliaRegistry
24 changes: 17 additions & 7 deletions .github/workflows/UnitTests.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Unit tests
name: Unit Tests

on:
- push
Expand All @@ -7,20 +7,30 @@ on:
jobs:
test:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental }}
strategy:
fail-fast: false
matrix:
julia-version: ['1.1', '1.2', '1.3', '1.4']
julia-version:
- '1.0' # LTS
- '1'
julia-arch: [x86]
os: [ubuntu-latest, windows-latest, macOS-latest]
experimental: [false]
include:
- julia-version: nightly
julia-arch: x86
os: ubuntu-latest
experimental: true

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Julia
uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.julia-version }}
- name: Install dependencies
run: julia ci_prep.jl
- name: Run tests
- name: Run Tests
uses: julia-actions/julia-runtest@latest
- name: Create CodeCov
uses: julia-actions/julia-processcoverage@v1
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,7 @@ docs/site/
Manifest.toml

.DS_Store

.benchmarkci
benchmark/*.json
benchmark/results
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,16 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

## [2.0.3] - 2020-06-13

### Added
- Julia LTS Support
- Benchmarks

### Changed
- Documentation.
- Updated CI for General Repository.

## [2.0.2] - 2020-05-21

### Fixed
Expand Down
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "GenomicFeatures"
uuid = "899a7d2d-5c61-547b-bef9-6698a8d05446"
authors = ["Kenta Sato <[email protected]>", "Ben J. Ward <[email protected]>", "Ciarán O’Mara <[email protected]>"]
version = "2.0.2"
version = "2.0.3"

[deps]
BioGenerics = "47718e42-2ac5-11e9-14af-e5595289c2ea"
Expand All @@ -12,7 +12,7 @@ IntervalTrees = "524e6230-43b7-53ae-be76-1e9e4d08d11b"
BioGenerics = "0.1"
DataStructures = "0.11, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17"
IntervalTrees = "1.0"
julia = "1.1"
julia = "1"

[extras]
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
Expand Down
11 changes: 2 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,8 @@ The GenomicFeatures package provides utilities for working with interval based g
It builds on [IntervalTrees](https://github.com/biojulia/intervaltrees.jl) to provide a data-structures and algorithms for various formats such as [BED](https://github.com/biojulia/bed.jl), [GFF3](https://github.com/biojulia/gff3.jl), [bigWig](https://github.com/biojulia/bigwig.jl) and [bigBed](https://github.com/biojulia/bigbed.jl).

## Installation
Releases of GenomicFeatures version 2.0.0 and above are registered and made available to install through BioJulia's package registry.
By default, Julia's package manager only uses the "General" package registry.

To add the BioJulia registry from the [Julia REPL](https://docs.julialang.org/en/v1/manual/getting-started/), press `]` to enter [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/), then enter the following command:
```julia
registry add https://github.com/BioJulia/BioJuliaRegistry.git
```

After adding the registry to your configuration, you can install GenomicFeatures while in [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/) with the following:
You can install the GenomicFeatures package from the [Julia REPL](https://docs.julialang.org/en/v1/manual/getting-started/).
Press `]` to enter [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/), then enter the following command:
```julia
add GenomicFeatures
```
Expand Down
9 changes: 9 additions & 0 deletions benchmark/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[deps]
BenchmarkTools = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf"
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
GenomicFeatures = "899a7d2d-5c61-547b-bef9-6698a8d05446"
PkgBenchmark = "32113eaa-f34f-5b0d-bd6c-c81e245fc73d"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"

[compat]
GenomicFeatures = "2"
55 changes: 55 additions & 0 deletions benchmark/benchmarks.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
using BenchmarkTools
# using BenchmarkTools: @benchmarkable, BenchmarkGroup

using GenomicFeatures

include(joinpath(@__DIR__, "..", "test", "Utilities.jl"))

import ..Utilities: random_intervals

N = 1000
SEED = 1234
SEQNAMES = "chr" .* string.(1:3)

intervals = random_intervals(SEQNAMES, 1000, N, SEED)
intervals_sorted = sort(intervals)

SUITE = BenchmarkGroup()

let suite = SUITE["accessors"] = BenchmarkGroup()
s0 = suite["$(typeof(intervals))"] = BenchmarkGroup()
s0["seqname"] = @benchmarkable(seqname.($intervals))
s0["leftposition"] = @benchmarkable(leftposition.($intervals))
s0["rightposition"] = @benchmarkable(rightposition.($intervals))
s0["strand"] = @benchmarkable(strand.($intervals))
s0["metadata"] = @benchmarkable(metadata.($intervals))
end

let suite = SUITE["sort"] = BenchmarkGroup()
suite["$(typeof(intervals))"] = @benchmarkable(sort(i), setup=(i = copy($intervals)))
end

let suite = SUITE["insert"] = BenchmarkGroup()
suite["shorthand"] = @benchmarkable(IntervalCollection($intervals_sorted))
suite["type"] = @benchmarkable(IntervalCollection{Int}($intervals_sorted))
end

let suite = SUITE["push"] = BenchmarkGroup()
suite["$(typeof(intervals))"] = @benchmarkable([push!(col, i) for i in $intervals], setup=(col=IntervalCollection{Int}()))
end

let suite = SUITE["eachoverlap"] = BenchmarkGroup()
intervals_a = intervals_sorted
intervals_b = sort(random_intervals(SEQNAMES, 1000, N, SEED+1))

col_a = IntervalCollection(intervals_a)
col_b = IntervalCollection(intervals_b)

As = [intervals_a, col_a]
Bs = [intervals_b, col_b]

for (A, B) in Iterators.product(As,Bs)
str = "$(typeof(A)), $(typeof(B))"
suite[str] = @benchmarkable(collect(eachoverlap($A,$B)))
end
end
24 changes: 24 additions & 0 deletions benchmark/runbenchmarks.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
using Pkg

Pkg.activate(@__DIR__)
Pkg.instantiate()

Pkg.status()

using PkgBenchmark

results = benchmarkpkg(
dirname(@__DIR__),
BenchmarkConfig(
env = Dict(
"JULIA_NUM_THREADS" => "1",
"OMP_NUM_THREADS" => "1",
),
)
)

dir_results = joinpath(@__DIR__, "results")
mkpath(dir_results)

writeresults(joinpath(dir_results, "$(results.date).json"), results)
export_markdown(joinpath(dir_results, "$(results.date).md"), results)
3 changes: 0 additions & 3 deletions ci_prep.jl

This file was deleted.

2 changes: 2 additions & 0 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ Pkg.instantiate()

using Documenter, GenomicFeatures

DocMeta.setdocmeta!(GenomicFeatures, :DocTestSetup, :(using GenomicFeatures); recursive=true)

makedocs(
format = Documenter.HTML(
edit_link = :commit
Expand Down
11 changes: 2 additions & 9 deletions docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,8 @@ The GenomicFeatures package provides utilities for working with interval based g
It builds on [IntervalTrees](https://github.com/biojulia/intervaltrees.jl) to provide a data-structures and algorithms for various formats such as [BED](https://github.com/biojulia/bed.jl), [GFF3](https://github.com/biojulia/gff3.jl), [bigWig](https://github.com/biojulia/bigwig.jl) and [bigBed](https://github.com/biojulia/bigbed.jl).

## Installation
Releases of GenomicFeatures version 2.0.0 and above are registered and made available to install through BioJulia's package registry.
By default, Julia's package manager only uses the "General" package registry.

To add the BioJulia registry from the [Julia REPL](https://docs.julialang.org/en/v1/manual/getting-started/), press `]` to enter [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/), then enter the following command:
```julia
registry add https://github.com/BioJulia/BioJuliaRegistry.git
```

After adding the registry to your configuration, you can install GenomicFeatures while in [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/) with the following:
You can install the GenomicFeatures package from the [Julia REPL](https://docs.julialang.org/en/v1/manual/getting-started/).
Press `]` to enter [pkg mode](https://docs.julialang.org/en/v1/stdlib/Pkg/), then enter the following command:
```julia
add GenomicFeatures
```
Expand Down
Loading

2 comments on commit 99632a3

@CiaranOMara
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/16300

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v2.0.3 -m "<description of version>" 99632a32b437e32625b3df23e78ea2cc271625d7
git push origin v2.0.3

Please sign in to comment.