{"id":13834787,"url":"https://github.com/SineZHAN/deepALplus","last_synced_at":"2025-07-10T07:30:54.147Z","repository":{"id":38351700,"uuid":"501078780","full_name":"SineZHAN/deepALplus","owner":"SineZHAN","description":"This is a toolbox for Deep Active Learning, an extension from previous work https://github.com/ej0cl6/deep-active-learning (DeepAL toolbox).","archived":false,"fork":false,"pushed_at":"2024-05-06T20:28:34.000Z","size":58,"stargazers_count":181,"open_issues_count":2,"forks_count":26,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-28T09:08:17.770Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SineZHAN.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-06-08T02:55:55.000Z","updated_at":"2025-04-29T18:53:31.000Z","dependencies_parsed_at":"2024-11-20T20:33:08.589Z","dependency_job_id":"a19890cd-dd31-4a0e-a7a5-ca50541b5c3c","html_url":"https://github.com/SineZHAN/deepALplus","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/SineZHAN/deepALplus","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SineZHAN%2FdeepALplus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SineZHAN%2FdeepALplus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SineZHAN%2FdeepALplus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SineZHAN%2FdeepALplus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SineZHAN","download_url":"https://codeload.github.com/SineZHAN/deepALplus/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SineZHAN%2FdeepALplus/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264545157,"owners_count":23625403,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T14:00:52.239Z","updated_at":"2025-07-10T07:30:53.739Z","avatar_url":"https://github.com/SineZHAN.png","language":"Python","funding_links":[],"categories":["3.3 AL in AI Fields - 人工智能背景中的主动学习"],"sub_categories":["**Tutorials - 教程**"],"readme":"# DeepAL+: Deep Active Learning Toolkit\n\nDeepAL+ is an extended toolkit originated from [DeepAL toolkit](https://github.com/ej0cl6/deep-active-learning). \nIncluding python implementations of the following active learning algorithms:\n\n- Random Sampling\n- Least Confidence [1]\n- Margin Sampling [2]\n- Entropy Sampling [3]\n- Uncertainty Sampling with Dropout Estimation [4]\n- Bayesian Active Learning Disagreement [4]\n- Core-Set Selection [5]\n- Adversarial margin [6]\n- Mean Standard Deviation [7]\n- Variation Ratios [8]\n- Cost-Effective Active Learning [9]\n- KMeans with scikit-learn library and with faiss-gpu library\n- Batch Active learning by Diverse Gradient Embeddings [10]\n- Loss Prediction Active Learning [11]\n- Variational Adversarial Active Learning [12]\n- Wasserstein Adversarial Active Learning [13]\n\nWe support 10 datasets, *MNIST*, *FashionMNIST*, *EMNIST*, *SVHN*, *CIFAR10*, *CIFAR100*, *Tiny ImageNet*, *BreakHis*, *PneumoniaMNIST*, *Waterbirds*. One can add a new dataset by adding a new function `get_newdataset()` in `data.py`.\n\n*Tiny ImageNet*, *BreakHis*, *PneumoniaMNIST* need to be downloaded manually, the corresponding data addresses can be found in `data.py`.\n\nIn DeepAL+, we use **ResNet18** as the basic classifier. One can replace it with other basic classifiers and add them to `nets.py`.\n\n## Prerequisites \n\n- numpy            1.21.2\n- scipy            1.7.1\n- pytorch          1.10.0\n- torchvision      0.11.1\n- scikit-learn     1.0.1\n- tqdm             4.62.3\n- ipdb             0.13.9\n- openml           0.12.2  \n- faiss-gpu        1.7.2\n- toma             1.1.0\n- opencv-python    4.5.5.64\n- wilds            2.0.0 (for waterbirds dataset only)\n\nYou can also use the following command to install the conda environment\n\n```\nconda env create -f environment.yml\n```\n\n`faiss-gpu` and wilds should use `pip install`.\n\n## Demo \n\n```\n  python demo.py \\\n      -a RandomSampling \\\n      -s 100 \\\n      -q 1000 \\\n      -b 100 \\\n      -d MNIST \\\n      --seed 4666 \\\n      -t 3 \\\n      -g 0\n```\nSee `arguments.py` for more instructions.\nWe have also constructed a comparative survey based on DeepAL+. \nPlease refer to [here](https://arxiv.org/pdf/2203.13450.pdf) for more details.\n\n## Citing\n\nPlease consider citing our paper if you use our code in your research or applications.\n\n```\n@article{zhan2022comparative,\n  title={A comparative survey of deep active learning},\n  author={Zhan, Xueying and Wang, Qingzhong and Huang, Kuan-hao and Xiong, Haoyi and Dou, Dejing and Chan, Antoni B},\n  journal={arXiv preprint arXiv:2203.13450},\n  year={2022}\n}\n```\n\n## Reference\n\n[1] A Sequential Algorithm for Training Text Classifiers, SIGIR, 1994\n\n[2] Active Hidden Markov Models for Information Extraction, IDA, 2001\n\n[3] Active learning literature survey. University of Wisconsin-Madison Department of Computer Sciences, 2009\n\n[4] Deep Bayesian Active Learning with Image Data, ICML, 2017\n\n[5] Active Learning for Convolutional Neural Networks: A Core-Set Approach, ICLR, 2018\n\n[6] Adversarial Active Learning for Deep Networks: a Margin Based Approach, arXiv, 2018\n\n[7]  Semantic segmentation of small objects and modeling of uncertainty in urban remote sensing images using deep convolutional neural networks, CVPR, 2016\n\n[8] Elementary applied statistics: for students in behavioral science. New\nYork: Wiley, 1965\n\n[9] Cost-effective active learning for deep image classification. TCSVT, 2016\n\n[10] Deep batch active learning by diverse, uncertain gradient lower bounds. ICLR, 2020\n\n[11] Learning loss for active learning. CVPR, 2019\n\n[12] Variational adversarial active learning, ICCV, 2019\n\n[13] Deep active learning: Unified and principled method for query and training. AISTATS, 2020\n\n\n## Contact\n\nIf you have any further questions or want to discuss Active Learning with me or contribute your own Active Learning approaches to our toolkit, please contact xueyingz@andrew.cmu.edu (my spare email is sinezhan17@gmail.com).\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSineZHAN%2FdeepALplus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FSineZHAN%2FdeepALplus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSineZHAN%2FdeepALplus/lists"}