Skip to content

Move domain-specific functionality to subpackages #240

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 39 commits into from
Jul 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
08ecf8c
Move domain-specific functionality to subpackages
lorenzoh Jun 20, 2022
fc16335
Add FastMakie.jl
lorenzoh Jun 20, 2022
355da49
Add tests to FastMakie
lorenzoh Jun 21, 2022
8936344
Fix loadfile
lorenzoh Jun 21, 2022
68cc553
Fix default show backend
lorenzoh Jun 21, 2022
c5b4518
Add tests and some package CI
lorenzoh Jun 21, 2022
30d27e1
Update FastVision CI
lorenzoh Jun 21, 2022
5136bef
update agai
lorenzoh Jun 21, 2022
aedf096
pt. 3
lorenzoh Jun 21, 2022
13a81cd
Add FastMakie dev dep
lorenzoh Jun 21, 2022
de33117
add FastMakie as test only dep
lorenzoh Jun 21, 2022
a036444
Try escaping double quotes
lorenzoh Jun 21, 2022
f5bd40c
pls work
lorenzoh Jun 21, 2022
8049753
Dev FastAI for test
lorenzoh Jun 21, 2022
946355d
use dev""
lorenzoh Jun 21, 2022
4804cf5
Try to fix for windows
lorenzoh Jun 21, 2022
6d568cb
dev FastVision
lorenzoh Jun 21, 2022
5651cc5
Don't use alias import
lorenzoh Jun 21, 2022
aa6b54e
Unqualified @recipe macro for 1.6 compat
lorenzoh Jun 21, 2022
1835047
Allow datadeps downloading
lorenzoh Jun 21, 2022
4754727
fix FastAI tests
lorenzoh Jun 21, 2022
23324bd
Use bash to fix windows
lorenzoh Jun 21, 2022
4aeb7a3
Add subpackage CI
lorenzoh Jun 21, 2022
83b878b
allow datadeps for tabular
lorenzoh Jun 21, 2022
2447cb4
run SciMLStyle
lorenzoh Jun 21, 2022
7aa3864
run SciMLStyle (FastVision/Text/Tabular)
lorenzoh Jun 21, 2022
d6c0809
Disable tabular windows
lorenzoh Jun 21, 2022
efd7069
Update parts of documentation and add GH actions
lorenzoh Jun 22, 2022
95fe66d
Update .md docs and start on notebooks
lorenzoh Jun 22, 2022
85ed09b
Fix Makie visualization for Label[Multi]
lorenzoh Jun 27, 2022
9102ccc
Add sysimage example
lorenzoh Jun 27, 2022
0b9e855
Fix issues with doubly wrapped blocks
lorenzoh Jun 27, 2022
cb9ea8b
Improve Makie axes
lorenzoh Jun 27, 2022
f3f3763
clean up
lorenzoh Jun 27, 2022
b05a2d1
Update recipe registration
lorenzoh Jul 3, 2022
a293a72
Rerun quickstart notebook
lorenzoh Jul 3, 2022
9bea44f
Update remaining notebooks
lorenzoh Jul 3, 2022
4c612ec
Merge branch 'master' into lo/fastvision
lorenzoh Jul 3, 2022
f818fd3
rerun SciMLStyle
lorenzoh Jul 3, 2022
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
57 changes: 57 additions & 0 deletions .github/workflows/ci-fastmakie.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: CI - FastMakie
on:
push:
paths-ignore:
- 'docs/**'
- 'FastTabular/**'
- 'FastText/**'
- 'FastVision/**'
- '*.md'
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- '1.6'
os:
- ubuntu-latest
- macOS-latest
- windows-latest
arch:
- x64

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: Dev FastAI
run: |
julia --color=yes --project=./FastMakie -e 'using Pkg; pkg"dev ."'
shell: bash
- name: Dev test dependencies
run: |
julia --color=yes --project=./FastMakie/test -e 'using Pkg; pkg"dev . ./FastMakie "'
shell: bash
- uses: julia-actions/julia-buildpkg@latest
with:
project: './FastMakie/'
- name: Run tests
run: |
julia --color=yes --depwarn=yes --project=./FastMakie/test -e 'include("FastMakie/test/runtests.jl")'
continue-on-error: ${{ matrix.version == 'nightly' }}
shell: bash
56 changes: 56 additions & 0 deletions .github/workflows/ci-fasttabular.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: CI - FastTabular
on:
push:
paths-ignore:
- 'docs/**'
- 'FastMakie/**'
- 'FastText/**'
- 'FastVision/**'
- '*.md'
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- '1.6'
os:
- ubuntu-latest
- macOS-latest
arch:
- x64

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: Dev FastAI
run: |
julia --color=yes --project=./FastTabular -e 'using Pkg; pkg"dev ."'
shell: bash
- name: Dev test dependencies
run: |
julia --color=yes --project=./FastTabular/test -e 'using Pkg; pkg"dev . ./FastTabular "'
shell: bash
- uses: julia-actions/julia-buildpkg@latest
with:
project: './FastTabular/'
- name: Run tests
run: |
julia --color=yes --depwarn=yes --project=./FastTabular/test -e 'include("FastTabular/test/runtests.jl")'
continue-on-error: ${{ matrix.version == 'nightly' }}
shell: bash
57 changes: 57 additions & 0 deletions .github/workflows/ci-fasttext.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: CI - FastText
on:
push:
paths-ignore:
- 'docs/**'
- 'FastMakie/**'
- 'FastTabular/**'
- 'FastVision/**'
- '*.md'
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- '1.6'
os:
- ubuntu-latest
- macOS-latest
- windows-latest
arch:
- x64

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: Dev FastAI
run: |
julia --color=yes --project=./FastText -e 'using Pkg; pkg"dev ."'
shell: bash
- name: Dev test dependencies
run: |
julia --color=yes --project=./FastText/test -e 'using Pkg; pkg"dev . ./FastText "'
shell: bash
- uses: julia-actions/julia-buildpkg@latest
with:
project: './FastText/'
- name: Run tests
run: |
julia --color=yes --depwarn=yes --project=./FastText/test -e 'include("FastText/test/runtests.jl")'
continue-on-error: ${{ matrix.version == 'nightly' }}
shell: bash
61 changes: 61 additions & 0 deletions .github/workflows/ci-fastvision.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: CI - FastVision
on:
push:
paths-ignore:
- 'docs/**'
- 'FastTabular/**'
- 'FastText/**'
- '*.md'
pull_request:
paths-ignore:
- 'docs/**'
- 'FastTabular/**'
- 'FastText/**'
- '*.md'
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- '1.6'
os:
- ubuntu-latest
- macOS-latest
arch:
- x64

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- name: Dev FastAI
run: |
julia --color=yes --project=./FastVision -e 'using Pkg; pkg"dev ."'
shell: bash
- name: Dev test dependencies
run: |
julia --color=yes --project=./FastVision/test -e 'using Pkg; pkg"dev . ./FastVision ./FastMakie"'
shell: bash
- uses: julia-actions/julia-buildpkg@latest
with:
project: './FastVision/'
- name: Run tests
run: |
julia --color=yes --depwarn=yes --project=./FastVision/test -e 'include("FastVision/test/runtests.jl")'
continue-on-error: ${{ matrix.version == 'nightly' }}
shell: bash
18 changes: 16 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
name: CI
on:
- push
- pull_request
push:
paths-ignore:
- 'docs/**'
- 'FastMakie/**'
- 'FastVision/**'
- 'FastTabular/**'
- 'FastText/**'
- '*.md'
pull_request:
paths-ignore:
- 'docs/**'
- 'FastMakie/**'
- 'FastVision/**'
- 'FastTabular/**'
- 'FastText/**'
- '*.md'
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pollenbuild.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pollenbuild
name: Documentation - Build

on:
push:
Expand All @@ -19,7 +19,7 @@ jobs:
version: '1.7'
- name: "Install package and docs dependencies"
run: |
julia --color=yes --project=./docs -e 'using Pkg; Pkg.add([Pkg.PackageSpec(path="."), Pkg.PackageSpec(url="https://github.com/c42f/JuliaSyntax.jl"), Pkg.PackageSpec(url="https://github.com/lorenzoh/ModuleInfo.jl"), Pkg.PackageSpec(url="https://github.com/lorenzoh/Pollen.jl", rev="main")]); Pkg.instantiate();'
julia --color=yes --project=./docs -e 'using Pkg; pkg"dev . ./FastVision ./FastMakie ./FastTabular https://github.com/c42f/JuliaSyntax.jl https://github.com/lorenzoh/ModuleInfo.jl https://github.com/lorenzoh/Pollen.jl"; Pkg.instantiate();'
- name: Build
run: |
julia --color=yes --project=./docs ./docs/make.jl ./pollen/dev/
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/pollenpr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Documentation - PR

on:
- pr

jobs:
pollen:
name: "Pollen - test documentation build"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v2
with:
ref: pollen
path: pollen
- uses: julia-actions/setup-julia@latest
with:
version: '1.7'
- name: "Install package and docs dependencies"
run: |
julia --color=yes --project=./docs -e 'using Pkg; pkg"dev . ./FastVision ./FastMakie ./FastTabular https://github.com/c42f/JuliaSyntax.jl https://github.com/lorenzoh/ModuleInfo.jl https://github.com/lorenzoh/Pollen.jl"; Pkg.instantiate();'
- name: Build
run: |
julia --color=yes --project=./docs ./docs/make.jl ./pollen/dev/
- name: Deploy
run: |
cd pollen
git config user.name github-actions
git config user.email github-actions@github.com
git add .
git commit -m "Build documentation data (Pollen.jl)"
git push

2 changes: 1 addition & 1 deletion .github/workflows/pollenstatic.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: pollenstatic
name: Documentation - Deploy

on:
push:
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ test/Manifest.toml
docs/Manifest.toml
development/**
Manifest.toml
**/*.jld2
**/*.jld2
*.so
13 changes: 9 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- (BREAKING) Now uses [MLUtils.jl](https://github.com/JuliaML/MLUtils.jl) to create and load datasets and data containers
- (BREAKING): Now uses [MLUtils.jl](https://github.com/JuliaML/MLUtils.jl) to create and load datasets and data containers
- Replaces dependencies MLDataPattern.jl, LearnBase.jl, and DataLoaders.jl
- Data containers must now implement the `Base.getindex`/`MLUtils.getobs` and `Base.length`/`MLUtils.numobs` interfaces.
- Previously exported `MLDataPattern.datasubset` has been replaced by `MLUtils.ObsView`
- Documentation has been updated appropriately

- (BREAKING): `FastAI.Vision` now lives in a separate package `FastVision` that holds all computer vision-related functionality.
- (BREAKING): `FastAI.Tabular` now lives in a separate package `FastTabular` that holds all tabular data-related functionality.

### Removed

- (BREAKING): `FastAI.Models` submodule. `Models` submodule of domain libraries, e.g. `FastVision.Models` should now be used.

## v0.4.3 (2022/05/14)

Expand Down Expand Up @@ -105,7 +110,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- New interfaces
- `blockbackbone` creates a default backbone for an input block
- Support for tabular data along with recipes and learning methods:
- [Tabular classification tutorial](https://fluxml.ai/FastAI.jl/dev/notebooks/tabularclassification.ipynb.html)
- [Tabular classification tutorial](https://fluxml.ai/FastAI.jl/dev/docs/notebooks/tabularclassification.ipynb.html)
- [`TabularPreprocessing`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.TabularPreprocessing.html), [`TableRow`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.TableRow.html), [`TableDataset`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.Datasets.TableDataset.html), [`TabularClassificiationSingle`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.TabularClassificationSingle.html), [`TabularRegression`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.TabularRegression.html)


Expand All @@ -115,7 +120,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- [README](https://fluxml.ai/FastAI.jl/dev/README.md.html)
- [Introduction](https://fluxml.ai/FastAI.jl/dev/docs/introduction.md.html)
- [Data containers](https://fluxml.ai/FastAI.jl/dev/docs/data_containers.md.html)
- Combined how-tos on training [into a single page](https://fluxml.ai/FastAI.jl/dev/notebooks/training.ipynb.html)
- Combined how-tos on training [into a single page](https://fluxml.ai/FastAI.jl/dev/docs/notebooks/training.ipynb.html)
- Breaking changes to [`methodlearner`](https://fluxml.ai/FastAI.jl/dev/REFERENCE/FastAI.methodlearner.html):
- now accepts `callbacks` as kwarg
- `validdata` no longer keyword
Expand Down
14 changes: 14 additions & 0 deletions FastMakie/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name = "FastMakie"
uuid = "ca994201-3d74-4fad-8816-f8bc5449c7c3"
authors = ["Lorenz Ohly", "Julia Community"]
version = "0.1.0"

[deps]
FastAI = "5d0beca9-ade8-49ae-ad0b-a3cf890e669f"
InlineTest = "bd334432-b1e7-49c7-a2dc-dd9149e4ebd6"
Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
NNlib = "872c559c-99b0-510c-b3b7-b6c96a88d5cd"

[compat]
FastAI = "0.5"
Makie = "0.17"
21 changes: 21 additions & 0 deletions FastMakie/src/FastMakie.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
module FastMakie

import FastAI: FastAI, createhandle, showblock!, AbstractBlock, OneHotTensor,
OneHotTensorMulti,
Label, LabelMulti, ShowBackend, ShowMakie, axiskwargs, showblock,
showblocks!, showblocks
using InlineTest
import Makie
import NNlib: softmax, sigmoid

include("axis.jl")
include("showmakie.jl")
include("blocks.jl")
include("lrfind.jl")

function __init__()
# When loaded, set default show backend
FastAI.SHOW_BACKEND[] = ShowMakie()
end

end
Loading