Граф коммитов

99 Коммитов

Автор SHA1 Сообщение Дата
Xiaoyu b0896bb953
Fix ort nightly pipeline (#1554)
## Describe your changes

Fix ort nightly pipeline

- Upgrade to cuda 12.6 + TensorRT 10.5.
- Fix python 3.8 example test.
- Fix & skip some tests.
- Fix yaml format.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2025-01-16 16:24:40 -08:00
Xiaoyu dcc0cb9905
Migrate pipeline linux test to docker image (#1529)
## Describe your changes

- Migrate pipeline linux test to docker image.
- Skip failed tests for further investigation. Potential fail reasons:
  - python 3.10
  - onnxruntime 1.20
  - docker in docker


## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2025-01-09 10:56:34 -08:00
shaahji 33bd7f50ac
Disable a few more tests (#1525)
## Disable a few more tests

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-12-16 12:24:25 -08:00
Jambay Kinley bb51b0aeff
CI: Remove ORT-stable/last pipeline yaml and status badge (#1523)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-12-12 15:58:59 -08:00
shaahji 5827c17bfa
Script to run a build against each commit from a failed CI build. (#1510)
## Script to run a build against each commit from a failed CI build.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-12-06 21:13:55 -08:00
Xiaoyu b4d28e328d
New document theme! (#1491)
## Describe your changes

- Migrate documents to new theme.
- Reconstruct the documents structure.
- Added new instructions.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link

---------

Co-authored-by: samuel100 <samkemp@microsoft.com>
2024-11-22 12:37:17 -08:00
Xiaoyu f47265f377
Fix several bugs & add Bert inc example to pipeline (#1492)
## Describe your changes

Fix Olive bugs & Add Bert inc examples to example pipeline.

- `batch_size` is needed for Inc dataloader. Set default size to 1.
- Custom eval func doesn't have batch_size as input.
- For `QuantizationAwareTraining` pass, `train_data_config` is not
required if user provides `training_loop_func`.
- Latest transformers package will automatically save trained model as
safetensors format. Add `save_safetensors` as false to train argument.
- Some passes may have nested data_config in its config. Update
auto-fill data_config logic to achieve this.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-11-18 14:03:15 -08:00
Jambay Kinley 25ed55eaa6
Phi3: Fix example (#1452)
## Describe your changes
Fix example that was broken by #1401.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
Fixes #1447
2024-11-01 11:26:05 -07:00
Jambay Kinley 3ea3496f88
CI: Use PublishCodeCoverageResults@2 (#1446)
## Describe your changes
PublishCodeCoverageResults@1 is deprecated and produces lots of warning
in the run page.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-11-01 10:37:39 -07:00
Jambay Kinley 37b651df7e
CI: Skip integ tests for fork builds, No PR validation for AML CI pipeline (#1443)
## Describe your changes
Due to new security restrictions, pipeline secrets are not available in
fork builds.
- Don't run integration tests that require secrets to download data or
submit jobs to aml on fork builds
- Moved example tests that require secret from Olive CI pipeline to
examples or azureml pipelines.
- Remove PR trigger for AML CI pipeline. It runs after merge anyways and
we don't want to worry about permissions for fork builds.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-10-30 20:49:05 -07:00
Xiaoyu 5197848bfa
Add example pipeline (#1418)
## Describe your changes

Add example pipeline

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-10-16 09:34:26 -07:00
Xiaoyu 86a443982b
Refactor cache (#1400)
## Describe your changes

Refactor cache system.

- Rename cloud cache to shared cache.
- Unify local cache structure and shared cache structure.
- Update cache structure and config.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-10-10 10:27:29 -07:00
Xiaoyu ad157bc419
Add llama2 example to pipeline (#1328)
## Describe your changes

Add llama2 example to pipeline

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-08-28 14:52:04 -07:00
Jambay Kinley ea4e55f312
CI: Make compatible with `ort>=1.19.0` (#1320)
## Describe your changes
- After ort 1.19.0, the histogram collector in onnxruntime static
quantization calibration hits errors with Nan ("ValueError: supplied
range of [nan, nan] is not finite"). There is no ETA for an
investigation or fix for this issue so we will only test static
quantization with MinMax calibration method.
- Remove config params for no-search configs that are set to defaults
- Use latest torch in cuda examples test since ort-gpu 1.19.0 is
compatible with it now. (needs cudnn 9.x)

Some lint fixes for new ruff version.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-08-15 19:35:45 -07:00
Jambay Kinley 64b79dcddd
CI: Use latest torch in nightly pipeline, SD: Pin diffusers version (#1286) 2024-08-08 10:43:16 -07:00
Xiaoyu 798508b4d3
Separate aml example test from pipeline (#1272)
## Describe your changes

- Separate aml example test from pipeline
- New aml example test pipeline had been setup.
- AML example pipeline will run once a week.
- AML example pipeline will be triggered when code merged, and pr
trigger for azureml client and aml system.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-08-02 17:01:51 -07:00
Jambay Kinley 7e0adf733a
CI: Remove resnet qat example test (#1262) 2024-07-25 20:10:00 -07:00
Jambay Kinley 626c631cd3
CI: Configurable `torch` version, SD: Pin `transformers` version (#1255)
## Describe your changes
CI:
- Based on the cuda setup on the test machine, there might be
incompatibilities between the cuda related dependencies between torch
and ort-gpu. Allow CI jobs to specify the version of torch they want to
run with.
- torch, olive and ort installation steps abstracted into a template.

SD:
- `transformers>=4.43.0` added sdpa and flash attention support to clip
models which can be disabled by providing `"attn_implementation" :
false` as load kwargs. However, `diffusers` hasn't been updated yet to
use this option yet.
- Pin the version until the issue is resolved.
- Issue tracking this:
https://github.com/huggingface/diffusers/issues/8957

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-25 00:58:09 -07:00
Xiaoyu c283d62bc8
remove performance check pipeline (#1257)
## Describe your changes

Remove performance check pipeline.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-25 00:43:08 -07:00
Jambay Kinley 2cd0c478c3
Custom `FORMAT-JSON` linter (#1249)
## Describe your changes
- Created a custom json linter that formats all json files based on
`max-line-length` and `indent` settings.
- Unlike `json.dumps`, this format also adds a space before or after
brackets and braces for better readability.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-23 10:48:21 -07:00
Jambay Kinley 5466284e66
CI: Only run component governance in package publish pipeline (#1250)
## Describe your changes
- Remove component governance step from the test pipelines. We don't
publish anything in these pipelines, so it is not necessary. This task
is flaky sometimes and fails due to out of disk error. There is no
option to set a different directory to fix this.
- Added the step to the `package_publish` pipeline which is used to
generate the wheel for pypi release. Ignore the docs and examples
directories since those are not part of the package.
- Added the pipeline specific variables in the pipeline yamls instead of
the job templates for easier maintenance.
 
## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-22 14:31:15 -07:00
Jambay Kinley aab163c561
Fix doc (#1242)
## Describe your changes
- Added `set -e` to the doc build step since `make html` failure doesn't
cause the build to fail automatically.
- Fix underline length

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-17 22:06:22 -07:00
Jambay Kinley 3980c8c61a
CI: Separate Bert CUDA local and aml test (#1232)
## Describe your changes
- Separate the bert cuda example test into local and aml tests
- AML test:
  - doesn't require to be run on a GPU pipeline agent. 
- Reduced the cases since we only want to test CUDA EP on aml. No need
to test the pass_flows or search strategies. Saves test time since the
aml gpu cluster is small and has longer queue times.
- Updated base image with cuda 11.8. Both torch and ort don't support
11.6 anymore
  - Updated the conda yamls

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-12 15:29:21 -07:00
Jambay Kinley f40023839e
CI: Set pytest and olive tempdir roots (#1219)
## Describe your changes
- Some tests download or save large data to the temporary directory.
There is not enough space the default partition so use workspace
instead.
- `olive.workflows.run` now accepts `tempdir` argument to set the
`tempfile.tempdir` before the workflow is run.


## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-07-01 13:10:50 -07:00
Jambay Kinley 98dd62f0b9
CI: Re-enable AzureML tests (#1216)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-06-28 11:43:12 -07:00
Jambay Kinley f0cedd22d9
CI: Re-enable integration tests and QC toolkit tests (#1215)
## Describe your changes
- Storage access for these tests have been resolved. Azure ML tests are
still blocked.
- Fix lint issues due to new ruff release 0.5.0

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [x] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [x] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-06-27 19:38:32 -07:00
Jambay Kinley b59ef7d6d1
CI: Skip AzureML and Integration tests (#1212)
## Describe your changes
Storage accounts are currently not accessible. Commenting out or
skipping affected tests until a solution is found.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-06-26 18:29:51 -07:00
Jambay Kinley 51392bcfd6
`trust_remote_code` for `load_dataset` config, CI: set pip and hf cache dirs (#1200)
## Describe your changes
- Same changes in https://github.com/microsoft/Olive/pull/1199:
`load_dataset` also requires `trust_remote_code` now
- Set `PIP_CACHE_DIR` and `HF_HOME` to use the workspace directory in ci
pipelines. This directory has enough space where as the default cache
directories are under `/` which doesn't have much space for the
`OLIVE_POOL_UBUNTU2004` pools. This leads to out of disk sometimes. From
test runs, the pip cache takes 3G+. The hf cache depends on the models
and datasets being tested.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link

---------

Co-authored-by: Hitesh Shah <hiteshshah@microsoft.com>
2024-06-17 21:11:13 -07:00
Jambay Kinley 88b7a6f01d
Add workflow schema to doc website (#1190)
## Describe your changes
- Add olive workflow schema to doc website. This schema file can be used
in IDEs when writing workflow configs.
- Config objects related to workflow are updated to use `Field` with
descriptions.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [x] Update documents if necessary.
- [x] Lint and apply fixes to your code by running `lintrunner -a`
- [x] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
Schema for olive workflow config json can be found at
https://microsoft.github.io/Olive/schema.json.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-06-06 13:55:03 -07:00
shaahji 1358acfa81
Cleanup DataConfig implementation (#1187) 2024-06-05 22:17:21 -07:00
shaahji c91cd72632
Remove HFConfig::dataset and update docs accordingly (#1151)
## Remove HFConfig::dataset and update docs accordingly
All data configs should now be defined under "data_configs" tag in
config and referenced by name for use.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [x] Make sure all tests can pass.
- [x] Update documents if necessary.
- [x] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-05-14 14:14:53 -07:00
trajep 3c8ae18d46
🪟 Using managed identity auth instead of sas token (#1137)
## Describe your changes

Using managed identify auth instead of sas token

This change is enabled with both code changes and azure setttings
updates(_to link the managed identiy and corresponding azure app,
**done**_).

After this PR, we need to remove the tokens and disable sas auth in
azure settings.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-05-07 09:46:10 +08:00
Mike Guo d7d44875f9
disable vitis CI examples test (#1122)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-04-28 19:18:52 +08:00
shaahji fc128ef41f
Remove HfConfig::dataset references in examples and tests (#1113)
## Remove HfConfig::dataset references in examples and tests

Remove references to HFConfig::dataset from input model in all examples
and tests. Moved the references to the dataset into data_configs and
updated references accordingly. This change also eliminates the need for
the constant __input_model_data_config__.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [x] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [x] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-04-26 15:40:00 -07:00
Jambay Kinley 9727802683
CI: skip for `examples/directml/llm` (#1097)
## Describe your changes
There are no example tests yet for this example so no need to run the
azure pipeline jobs.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-04-19 03:34:14 -07:00
Jambay Kinley 2f4da5ced8
Update `skip_supported_eps_check`, Fix Mobilenet QNN EP example (#1076) 2024-04-11 21:50:11 -07:00
Jambay Kinley 865022c3ea
CI: Use managed identity for Azure authentication (#1060)
## Describe your changes
The workload federated identity from the service connection is only
[valid for 10
minutes](https://learn.microsoft.com/en-us/azure/devops/pipelines/release/troubleshoot-workload-identity?view=azure-devops#error-messages).
This is not enough for long running jobs.
- Instead use user assigned managed identity from the 1es pool agent for
authentication.
- Change `AzureCLI` task to `script` since we don't need the az login
using the service connection anymore.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-04-09 13:35:50 +08:00
Jambay Kinley ea5a3cdc02
CI: Exclude managed identity from azureml client credentials (#1040)
## Describe your changes
Our pipeline agents have their own managed identities which take
precedence over the AzureCLI task's own credentials. However, these
managed identities don't have permissions to run jobs on our workspace.

Exclude managed identity for credential so that we don't have to use the
workaround with environment variables.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-03-28 21:46:09 +08:00
Mike Guo 44de528b7f
Unify accelerator and ep concept into system (#998)
## Describe your changes
* In this PR, the execution_providers is moved from engine to system
config. typical config looks like
```json
    "systems": {
        "local_system": {
            "type": "LocalSystem",
            "config": {
                "accelerators": [
                    {
                        "device": "gpu",
                        "execution_providers": [
                            "CPUExecutionProvider"
                        ]
                    }
                ]
            }
        }
    },
  "engine": {
        "host": "local_system",
        "target": "local_system",
}

```
Please note the above config is optional if we only use local system
with default execution providers.
the device and execution_providers are both optional but they cannot be
all None if accelerators are specified.

* the `infer_accelerators_from_execution_providers` is changed to ignore
the CPUExecutionProvider. As the result, the `["CPUExecutionProvider",
"CUDAExecutionProvider"]` will be inferred as `gpu`

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-03-21 08:02:14 +08:00
Jambay Kinley 01620cec7f
Mistral: Readme update and generation using optimum (#1004) 2024-03-08 13:01:02 -08:00
trajep c2c50e3f84
📩 enable sd example ci trigger (#997)
## Describe your changes
1. trigger ci if sd example is changed
2. fix the import error as the utils under sd is same with the one in
e2e test folder.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.
- [ ] Is this PR including examples changes? If yes, please remember to
update [example
documentation](https://github.com/microsoft/Olive/blob/main/docs/source/examples.md)
in a follow-up PR.

## (Optional) Issue link
2024-03-07 16:30:22 +08:00
Jambay Kinley 0c62538de3
Re-enable bert cpu docker test in CI (#990) 2024-03-05 22:49:16 -08:00
Mike Guo e420baa03e
try to fix the CI failure (#968)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-02-28 13:09:04 +08:00
trajep 8a076dcdf9
🪟 snpe windows case (#945)
## Describe your changes
To complete the SNPE support in windows. 
Previously Olive only support to run SNPE toolkit in windows. In this
PR, I tried to:
1. Test the SNPE toolkit in windows and add the required env variables
for SNPE to run. Several differences between run in windows and linux:
- In windows, only the executable file can be find if it's parent folder
in system PATH. That need olive to resolve the full file path to run for
those snpe-tools which are python file but not .exe.
- In windows, to ensure Python.exe can be initialized successfully,
olive need to copy the SYSTEMROOT and other env variables to run the
cmd.
https://stackoverflow.com/questions/58997105/fatal-python-error-failed-to-get-random-numbers-to-initialize-python
2. Enable windows snpe toolkit e2e tests case with Inception model.

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-02-21 14:05:42 +08:00
Jambay Kinley b96fb29567
MobileNet: Update qnn ep quantization example (#937) 2024-02-12 17:38:33 -08:00
trajep 05f94584c7
🏂 Inception linux snpe e2e tests (#929)
## Describe your changes
Inception linux snpe e2e tests

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-02-06 13:18:53 -08:00
Mike Guo 3c25717980
enable more ruff rules (#927)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-02-04 16:37:23 +08:00
Mike Guo 44ef4ffbda
enable bert docker in last ci pipeline (#920)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-02-01 15:11:30 +08:00
Emma Ning 04045861c9
Documentation refactoring (#909)
## Describe your changes

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [X] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link

---------

Co-authored-by: Emma <ningqiongnq@gmail.com>
Co-authored-by: Mike Guo <myguo@microsoft.com>
Co-authored-by: Mike Guo <guotuofeng@gmail.com>
2024-01-31 13:54:31 +08:00
Mike Guo 70e0e1f6cd
reenable black sort with black 24.1.0 (#903)
## Describe your changes
In PR https://github.com/microsoft/Olive/pull/902, I temporary disable
black-isort to dismiss the formatting issue related to new black 24.1.0.

I reenable it by upgrading to latest black version

## Checklist before requesting a review
- [ ] Add unit tests for this change.
- [ ] Make sure all tests can pass.
- [ ] Update documents if necessary.
- [ ] Lint and apply fixes to your code by running `lintrunner -a`
- [ ] Is this a user-facing change? If yes, give a description of this
change to be included in the release notes.

## (Optional) Issue link
2024-01-26 17:53:10 +08:00