-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from owkin/release_1
- Loading branch information
Showing
158 changed files
with
34,167 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Tests/MAExamples/Base/data/**/* filter=lfs diff=lfs merge=lfs -text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: examples | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
- release** | ||
|
||
jobs: | ||
MAExamples: | ||
runs-on: self-hosted | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
lfs: true | ||
- name: Pull lfs | ||
run: git lfs pull | ||
|
||
- name: Setup Conda Environment | ||
run: | | ||
conda create --name maexamples-ci python=3.7 | ||
conda env list | ||
- name: Install Python Library | ||
working-directory: Tests/MAExamples/Base | ||
run: | | ||
conda activate maexamples-ci | ||
pip="$(dirname `which python`)"/pip | ||
$pip install -e . | ||
- name: Test | ||
run: | | ||
conda activate maexamples-ci | ||
swift test -c release --filter MAExamples | ||
- name: Remove Conda Environment | ||
if: always() | ||
run: conda env remove --name maexamples-ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: integration-tests | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
- release** | ||
|
||
jobs: | ||
MATorchTests: | ||
runs-on: self-hosted | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup Conda Environment | ||
run: | | ||
conda create --name matorch-ci python=3.7 | ||
conda env list | ||
- name: Install Python Library | ||
working-directory: Tests/MATorchTests/Base | ||
run: | | ||
conda activate matorch-ci | ||
pip="$(dirname `which python`)"/pip | ||
$pip install -e . | ||
- name: Test | ||
run: | | ||
conda activate matorch-ci | ||
swift test --filter MATorchTests | ||
- name: Remove Conda Environment | ||
if: always() | ||
run: conda env remove --name matorch-ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: unit-tests | ||
|
||
on: [push] | ||
|
||
jobs: | ||
MAKitTests: | ||
runs-on: self-hosted | ||
|
||
steps: | ||
- uses: swift-actions/setup-swift@v1 | ||
with: | ||
swift-version: "5.7.0" | ||
- uses: actions/checkout@v3 | ||
- name: Build | ||
run: swift build | ||
- name: Test | ||
run: swift test --filter MAKitTests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
.DS_Store | ||
/.build | ||
/Packages | ||
/*.xcodeproj | ||
xcuserdata/ | ||
DerivedData/ | ||
.swiftpm/config/registries.json | ||
.swiftpm/xcode/package.xcworkspace/* | ||
.netrc | ||
|
||
.idea/ | ||
*.egg-info/ | ||
__pycache__/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,178 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<Scheme | ||
LastUpgradeVersion = "1400" | ||
version = "1.3"> | ||
<BuildAction | ||
parallelizeBuildables = "YES" | ||
buildImplicitDependencies = "YES"> | ||
<BuildActionEntries> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit_MAKit" | ||
BuildableName = "MAKit_MAKit" | ||
BlueprintName = "MAKit_MAKit" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit" | ||
BuildableName = "MAKit" | ||
BlueprintName = "MAKit" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "NO" | ||
buildForArchiving = "NO" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKitTests" | ||
BuildableName = "MAKitTests" | ||
BlueprintName = "MAKitTests" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MATestsUtils" | ||
BuildableName = "MATestsUtils" | ||
BlueprintName = "MATestsUtils" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit_MAExamples" | ||
BuildableName = "MAKit_MAExamples" | ||
BlueprintName = "MAKit_MAExamples" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit_MATorchTests" | ||
BuildableName = "MAKit_MATorchTests" | ||
BlueprintName = "MAKit_MATorchTests" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
</BuildActionEntries> | ||
</BuildAction> | ||
<TestAction | ||
buildConfiguration = "Release" | ||
selectedDebuggerIdentifier = "" | ||
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn" | ||
shouldUseLaunchSchemeArgsEnv = "YES" | ||
codeCoverageEnabled = "YES" | ||
onlyGenerateCoverageForSpecifiedTargets = "YES"> | ||
<CodeCoverageTargets> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit" | ||
BuildableName = "MAKit" | ||
BlueprintName = "MAKit" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</CodeCoverageTargets> | ||
<Testables> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKitTests" | ||
BuildableName = "MAKitTests" | ||
BlueprintName = "MAKitTests" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</TestableReference> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAExamples" | ||
BuildableName = "MAExamples" | ||
BlueprintName = "MAExamples" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</TestableReference> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MATorchTests" | ||
BuildableName = "MATorchTests" | ||
BlueprintName = "MATorchTests" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</TestableReference> | ||
</Testables> | ||
</TestAction> | ||
<LaunchAction | ||
buildConfiguration = "Debug" | ||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
launchStyle = "0" | ||
useCustomWorkingDirectory = "NO" | ||
ignoresPersistentStateOnLaunch = "NO" | ||
debugDocumentVersioning = "YES" | ||
debugServiceExtension = "internal" | ||
allowLocationSimulation = "YES"> | ||
</LaunchAction> | ||
<ProfileAction | ||
buildConfiguration = "Release" | ||
shouldUseLaunchSchemeArgsEnv = "YES" | ||
savedToolIdentifier = "" | ||
useCustomWorkingDirectory = "NO" | ||
debugDocumentVersioning = "YES"> | ||
<MacroExpansion> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "MAKit_MAKit" | ||
BuildableName = "MAKit_MAKit" | ||
BlueprintName = "MAKit_MAKit" | ||
ReferencedContainer = "container:"> | ||
</BuildableReference> | ||
</MacroExpansion> | ||
</ProfileAction> | ||
<AnalyzeAction | ||
buildConfiguration = "Debug"> | ||
</AnalyzeAction> | ||
<ArchiveAction | ||
buildConfiguration = "Release" | ||
revealArchiveInOrganizer = "YES"> | ||
</ArchiveAction> | ||
</Scheme> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# | ||
# Below is a list of people and organizations that have contributed | ||
# to the MAKit project. Names should be added to the list like so: | ||
# | ||
# Name/Organization <email address> | ||
# | ||
|
||
Jean-François Reboud <[email protected]> |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# | ||
# Below is a list of MAKit code owners. | ||
# They are responsible for: | ||
# | ||
# - reviewing PR before it can be merged into the main branch | ||
# - handle GitHub Issues lifecycle | ||
# | ||
# Code owneers are added by existing code owners, | ||
# everybody can suggeset new code owners. | ||
# | ||
|
||
* @jean-francoisreboud |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# 👷 Architecture | ||
|
||
Here are the different components of MAKit: | ||
|
||
- [MAKit](MAKit.md) | ||
- [MATestsUtils](MATestsUtils.md) | ||
- [MAKitTests](MAKitTests.md) | ||
- [MATorchTests](MATorchTests.md) | ||
- [MAExamples](MAExamples.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# 👷 MAExamples | ||
|
||
`MAExamples` contains examples that show how to interact with `MAKit`. | ||
|
||
See the [examples](../Examples/EXAMPLES.md) documentation for more details. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# 👷 MAKit | ||
|
||
`MAKit` contains the different API needed to train models and interact | ||
with them. | ||
|
||
See the [main concepts](../Concepts/CONCEPTS.md) to know more about `MAKit`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# 👷 MAKitTests | ||
|
||
`MAKitTests` contains unit tests of `MAKit`. | ||
|
||
Some of them are systematic and repeated over many different setups to ensure | ||
that every layer, optimizer, activation function ... is tested. | ||
|
||
## Systematic Tests | ||
|
||
- gradient checking tests: compare gradients of weights | ||
computed through `backward` to an estimation computed through `forwardGC` | ||
|
||
- flow tests: compare gradients computed in CPU and GPU | ||
|
||
- reset tests: compare gradients computed in CPU and GPU after a reset | ||
|
||
- reverse tests: compare gradients computed in CPU and GPU after exchanging | ||
the execution context | ||
(the model CPU will be executed on the GPU and vice versa) | ||
|
||
- inference tests: compare loss in CPU and GPU during the inference phase | ||
|
||
- load tests: compare loss in CPU and GPU after loading models from the disk | ||
|
||
- transform tests: compare loss in CPU and GPU after applying transforms on | ||
the model | ||
|
||
- norm tests: test that we can clip the gradients of weights | ||
|
||
## Other Tests | ||
|
||
Other tests are not repeated over many different setups. | ||
They concern some specific components: | ||
|
||
- `MetalKernelTests`: ensure that every Metal kernel builds correctly | ||
- `OptimizerVariablesTests`: test scheduler for optimizers and variables | ||
- `UpdateManagementTests`: test we can control the training flow |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# 👷 MATestsUtils | ||
|
||
`MATestsUtils` contains utils to enable the testing of plugins of `MAKit`. | ||
|
||
To know more about plugins, see [this documentation](../Concepts/PLUGIN.md). |
Oops, something went wrong.