/maia

:m: BIIGLE module for the Machine Learning Assisted Image Annotation method

Primary LanguagePHPGNU General Public License v3.0GPL-3.0

BIIGLE MAIA Module

Test status

This is the BIIGLE module module for the Machine Learning Assisted Image Annotation method.

Installation

  1. Run composer require biigle/maia.
  2. Install the Python dependencies with pip install -r requirements.txt.
  3. Add Biigle\Modules\Maia\MaiaServiceProvider::class to the providers array in config/app.php.
  4. Run php artisan vendor:publish --tag=public to publish the public assets of this module.
  5. Run docker-compose exec app php artisan migrate to create the new database tables.
  6. Configure a storage disk each for the training proposal and annotation candidate patches. Set the MAIA_TRAINING_PROPOSAL_STORAGE_DISK and MAIA_ANNOTATION_CANDIDATE_STORAGE_DISK variables in the .env file to the name of the respective storage disk. Do not use the same disk for both! The content of the storage disks should be publicly accessible. Example for local disks:
    // MAIA_TRAINING_PROPOSAL_STORAGE_DISK
    'maia-tp' => [
        'driver' => 'local',
        'root' => storage_path('app/public/maia-tp-patches'),
        'url' => env('APP_URL').'/storage/maia-tp-patches',
        'visibility' => 'public',
    ],
    // MAIA_ANNOTATION_CANDIDATE_STORAGE_DISK
    'maia-ac' => [
        'driver' => 'local',
        'root' => storage_path('app/public/maia-ac-patches'),
        'url' => env('APP_URL').'/storage/maia-ac-patches',
        'visibility' => 'public',
    ],
    This requires the link storage -> ../storage/app/public in the public directory.

Configuration

New processing jobs are submitted to the default queue of the gpu connection. You can configure these with the MAIA_JOB_QUEUE and MAIA_JOB_CONNECTION environment variables. Optionally, you can configure a different queue (but not connection) fot the jobs to generate feature vectors with MAIA_FEATURE_VECTOR_QUEUE. This can be used to give jobs to generate feature vectors a higher priority.

References

Reference publications that you should cite if you use MAIA for one of your studies.

Developing

Take a look at the development guide of the core repository to get started with the development setup.

Want to develop a new module? Head over to the biigle/module template repository.

Contributions and bug reports

Contributions to BIIGLE are always welcome. Check out the contribution guide to get started.