Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added chunking options to analysis level #944

Merged
merged 19 commits into from
Jan 15, 2024

Conversation

sambles
Copy link
Contributor

@sambles sambles commented Jan 12, 2024

Added chunking options to analysis level

Added a new endpoint /v2/analyses/{id}/chunking_configuration/ this uses the same Django model as /v2/models/{id}/chunking_configuration/, ModelChunkingOptions , but only applies to a single analysis.

{
  lookup_strategy:  `DYNAMIC_CHUNKS`,
  dynamic_locations_per_lookup: 1000,
  loss_strategy: `DYNAMIC_CHUNKS`,
  dynamic_events_per_analysis: 1000,
  dynamic_chunks_max: 250,
}

Usage

On analyses creation the value of chunking_configuration is equal to None, if not set then the options are read at the model level /v2/models/{id}/chunking_configuration/.

After a POST to /v2/analyses/{id}/chunking_configuration/ the analysis {id} will have its own chunking options which now overrides the default from the model level.

Related fixes

  • Fixed Issue #681 - Sub-task object danggling log files.
  • Added environment variable OASIS_DISABLE_V2_API={True|False}, when set to true the v2 endpoints are disabled and the server can only run analysis in single server execution (intended for docker-compose or debugging)

@sambles sambles self-assigned this Jan 12, 2024
@sambles sambles linked an issue Jan 12, 2024 that may be closed by this pull request
@sambles sambles linked an issue Jan 12, 2024 that may be closed by this pull request
@sambles sambles merged commit e0f832c into main Jan 15, 2024
23 checks passed
@sambles sambles deleted the feature/928-set-chunking-per-analysis branch January 15, 2024 11:33
sambles added a commit that referenced this pull request Jan 15, 2024
* Add missing check for build up of queue messages

* First pass

* Attach chunking options to analyses model

* Add chunking endpoints to analysis

* Set task-controller to check both model and analysis chunking options

* PEP

* flake

* Add migrations

* update tests

* Add env var to disable v2 api

* f]

* remove special case -- chunk=1 now means run losses in a single ktools pipe

* Debug prints

* Read chunking options from analysis when running job validation

* fix & pep

* f

* Fixed -- removed debug logging

* Remove logging

* Update test expected
@awsbuild awsbuild added this to the 2.3.0 milestone Feb 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Platform 2 - Set chunking options at analysis level Sub-task object danggling log files.
2 participants