├── .github └── workflows │ ├── python-package.yml │ └── wheels.yml ├── .gitignore ├── .travis.yml ├── LICENSE ├── README.md ├── apricot ├── __init__.py ├── functions │ ├── __init__.py │ ├── base.py │ ├── custom.py │ ├── facilityLocation.py │ ├── featureBased.py │ ├── graphCut.py │ ├── maxCoverage.py │ ├── mixture.py │ ├── saturatedCoverage.py │ └── sumRedundancy.py ├── optimizers.py └── utils.py ├── dev-requirements.txt ├── docs ├── Makefile ├── _templates │ └── layout.html ├── conf.py ├── features │ ├── knapsack.rst │ ├── sparse.rst │ └── streaming.rst ├── functions │ ├── facilityLocation.rst │ ├── featureBased.rst │ ├── graphCut.rst │ ├── maxCoverage.rst │ ├── mixture.rst │ ├── saturatedCoverage.rst │ └── sumRedundancy.rst ├── imgs │ ├── embeddings.png │ └── fl-ml.png ├── index.rst ├── logos │ └── apricot-logo.png ├── make.bat ├── optimizers │ ├── approx-lazy.rst │ ├── bidirectional.rst │ ├── greedi.rst │ ├── lazy.rst │ ├── modular.rst │ ├── naive.rst │ ├── sample.rst │ ├── stochastic.rst │ └── two-stage.rst └── submodular.rst ├── img ├── 20newsgroups.png ├── attributionselection.png ├── embeddings.png ├── facilityLocationGIF.py └── fl-ml.png ├── setup.py ├── slides └── apricot PyData Global 2021.pdf ├── tests ├── __init__.py ├── test_functions │ ├── __init__.py │ ├── test_facility_location.py │ ├── test_feature_based.py │ ├── test_graph_cut.py │ ├── test_max_coverage.py │ ├── test_mixture_feature_based.py │ ├── test_mixture_graph_based.py │ ├── test_saturated_coverage.py │ └── test_sum_redundancy.py └── test_optimizers │ ├── __init__.py │ ├── test_knapsack_facility_location.py │ └── test_knapsack_feature_based.py └── tutorials ├── 1. Overview of Apricot.ipynb ├── 2. Introduction to Submodular Optimization.ipynb ├── 3. Model-Based Selection.ipynb ├── 3. Using Sparse Inputs.ipynb ├── 4. Defining Custom Functions.ipynb ├── 5. Defining Custom Optimizers.ipynb ├── 6. Streaming Submodular Optimization.ipynb ├── Example A. Facility Location on MNIST and Fashion-MNIST.ipynb ├── Example B. Airport Selection.ipynb ├── Workshop Tutorial 1. Practical Apricot Usage - Answers.ipynb ├── Workshop Tutorial 1. Practical Apricot Usage - Worksheet.ipynb ├── airports.csv └── routes.csv /.github/workflows/python-package.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/.github/workflows/python-package.yml -------------------------------------------------------------------------------- /.github/workflows/wheels.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/.github/workflows/wheels.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/.gitignore -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/.travis.yml -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/README.md -------------------------------------------------------------------------------- /apricot/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/__init__.py -------------------------------------------------------------------------------- /apricot/functions/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/__init__.py -------------------------------------------------------------------------------- /apricot/functions/base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/base.py -------------------------------------------------------------------------------- /apricot/functions/custom.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/custom.py -------------------------------------------------------------------------------- /apricot/functions/facilityLocation.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/facilityLocation.py -------------------------------------------------------------------------------- /apricot/functions/featureBased.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/featureBased.py -------------------------------------------------------------------------------- /apricot/functions/graphCut.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/graphCut.py -------------------------------------------------------------------------------- /apricot/functions/maxCoverage.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/maxCoverage.py -------------------------------------------------------------------------------- /apricot/functions/mixture.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/mixture.py -------------------------------------------------------------------------------- /apricot/functions/saturatedCoverage.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/saturatedCoverage.py -------------------------------------------------------------------------------- /apricot/functions/sumRedundancy.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/functions/sumRedundancy.py -------------------------------------------------------------------------------- /apricot/optimizers.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/optimizers.py -------------------------------------------------------------------------------- /apricot/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/apricot/utils.py -------------------------------------------------------------------------------- /dev-requirements.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/dev-requirements.txt -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/Makefile -------------------------------------------------------------------------------- /docs/_templates/layout.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/_templates/layout.html -------------------------------------------------------------------------------- /docs/conf.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/conf.py -------------------------------------------------------------------------------- /docs/features/knapsack.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/features/knapsack.rst -------------------------------------------------------------------------------- /docs/features/sparse.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/features/sparse.rst -------------------------------------------------------------------------------- /docs/features/streaming.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/features/streaming.rst -------------------------------------------------------------------------------- /docs/functions/facilityLocation.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/facilityLocation.rst -------------------------------------------------------------------------------- /docs/functions/featureBased.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/featureBased.rst -------------------------------------------------------------------------------- /docs/functions/graphCut.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/graphCut.rst -------------------------------------------------------------------------------- /docs/functions/maxCoverage.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/maxCoverage.rst -------------------------------------------------------------------------------- /docs/functions/mixture.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/mixture.rst -------------------------------------------------------------------------------- /docs/functions/saturatedCoverage.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/saturatedCoverage.rst -------------------------------------------------------------------------------- /docs/functions/sumRedundancy.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/functions/sumRedundancy.rst -------------------------------------------------------------------------------- /docs/imgs/embeddings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/imgs/embeddings.png -------------------------------------------------------------------------------- /docs/imgs/fl-ml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/imgs/fl-ml.png -------------------------------------------------------------------------------- /docs/index.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/index.rst -------------------------------------------------------------------------------- /docs/logos/apricot-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/logos/apricot-logo.png -------------------------------------------------------------------------------- /docs/make.bat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/make.bat -------------------------------------------------------------------------------- /docs/optimizers/approx-lazy.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/approx-lazy.rst -------------------------------------------------------------------------------- /docs/optimizers/bidirectional.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/bidirectional.rst -------------------------------------------------------------------------------- /docs/optimizers/greedi.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/greedi.rst -------------------------------------------------------------------------------- /docs/optimizers/lazy.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/lazy.rst -------------------------------------------------------------------------------- /docs/optimizers/modular.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/modular.rst -------------------------------------------------------------------------------- /docs/optimizers/naive.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/naive.rst -------------------------------------------------------------------------------- /docs/optimizers/sample.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/sample.rst -------------------------------------------------------------------------------- /docs/optimizers/stochastic.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/stochastic.rst -------------------------------------------------------------------------------- /docs/optimizers/two-stage.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/optimizers/two-stage.rst -------------------------------------------------------------------------------- /docs/submodular.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/docs/submodular.rst -------------------------------------------------------------------------------- /img/20newsgroups.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/img/20newsgroups.png -------------------------------------------------------------------------------- /img/attributionselection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/img/attributionselection.png -------------------------------------------------------------------------------- /img/embeddings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/img/embeddings.png -------------------------------------------------------------------------------- /img/facilityLocationGIF.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/img/facilityLocationGIF.py -------------------------------------------------------------------------------- /img/fl-ml.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/img/fl-ml.png -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/setup.py -------------------------------------------------------------------------------- /slides/apricot PyData Global 2021.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/slides/apricot PyData Global 2021.pdf -------------------------------------------------------------------------------- /tests/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/test_functions/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/test_functions/test_facility_location.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_facility_location.py -------------------------------------------------------------------------------- /tests/test_functions/test_feature_based.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_feature_based.py -------------------------------------------------------------------------------- /tests/test_functions/test_graph_cut.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_graph_cut.py -------------------------------------------------------------------------------- /tests/test_functions/test_max_coverage.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_max_coverage.py -------------------------------------------------------------------------------- /tests/test_functions/test_mixture_feature_based.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_mixture_feature_based.py -------------------------------------------------------------------------------- /tests/test_functions/test_mixture_graph_based.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_mixture_graph_based.py -------------------------------------------------------------------------------- /tests/test_functions/test_saturated_coverage.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_saturated_coverage.py -------------------------------------------------------------------------------- /tests/test_functions/test_sum_redundancy.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_functions/test_sum_redundancy.py -------------------------------------------------------------------------------- /tests/test_optimizers/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/test_optimizers/test_knapsack_facility_location.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_optimizers/test_knapsack_facility_location.py -------------------------------------------------------------------------------- /tests/test_optimizers/test_knapsack_feature_based.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tests/test_optimizers/test_knapsack_feature_based.py -------------------------------------------------------------------------------- /tutorials/1. Overview of Apricot.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/1. Overview of Apricot.ipynb -------------------------------------------------------------------------------- /tutorials/2. Introduction to Submodular Optimization.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/2. Introduction to Submodular Optimization.ipynb -------------------------------------------------------------------------------- /tutorials/3. Model-Based Selection.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/3. Model-Based Selection.ipynb -------------------------------------------------------------------------------- /tutorials/3. Using Sparse Inputs.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/3. Using Sparse Inputs.ipynb -------------------------------------------------------------------------------- /tutorials/4. Defining Custom Functions.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/4. Defining Custom Functions.ipynb -------------------------------------------------------------------------------- /tutorials/5. Defining Custom Optimizers.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/5. Defining Custom Optimizers.ipynb -------------------------------------------------------------------------------- /tutorials/6. Streaming Submodular Optimization.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/6. Streaming Submodular Optimization.ipynb -------------------------------------------------------------------------------- /tutorials/Example A. Facility Location on MNIST and Fashion-MNIST.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/Example A. Facility Location on MNIST and Fashion-MNIST.ipynb -------------------------------------------------------------------------------- /tutorials/Example B. Airport Selection.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/Example B. Airport Selection.ipynb -------------------------------------------------------------------------------- /tutorials/Workshop Tutorial 1. Practical Apricot Usage - Answers.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/Workshop Tutorial 1. Practical Apricot Usage - Answers.ipynb -------------------------------------------------------------------------------- /tutorials/Workshop Tutorial 1. Practical Apricot Usage - Worksheet.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/Workshop Tutorial 1. Practical Apricot Usage - Worksheet.ipynb -------------------------------------------------------------------------------- /tutorials/airports.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/airports.csv -------------------------------------------------------------------------------- /tutorials/routes.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jmschrei/apricot/HEAD/tutorials/routes.csv --------------------------------------------------------------------------------