aws / aws/sagemaker-python-sdk

CodeArtifact login support for FrameworkProcessor Jobs

Chiusa
#4,144 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
component: training type: feature request
Lingua principale
Python
Stelle
2.3k
Fork
1.3k
Merge medio
1g 22h
PR unite (30g)
35

Descrizione

**Describe the feature you'd like**
We use private Python packages hosted in CodeArtifact for some of our common preprocessing and training code. However, currently there is no way to have a processing job authenticate to CodeArtifact before it installs Python requirements from a `requirements.txt` file.

Currently, we get an authorization token from CodeArtifact, write it to a file, and include that file with our processing/training code that gets pushed to S3 and pulled down in the jobs. This is really just a cleaner way to implement the same thing.

**How would this feature be used? Please describe.**
The simplest way to implement this would be to borrow code from the [sagemaker-training-toolkit](https://github.com/aws/sagemaker-training-toolkit/blob/master/src/sagemaker_training/modules.py#L186-L235) package to parse a CodeArtifact repo URL from a CodeArtifact repo ARN, and then simply write this token as an index into the `runproc.sh` file that gets generated in the [_generate_framework_script()](https://github.com/akuma12/sagemaker-python-sdk/blob/master/src/sagemaker/processing.py#L1830-L1864) method of the FrameworkProcessor class.

Adding an optional `codeartifact_repo_arn` parameter to the `.run()` method would allow it to be passed to the `_generate_framework_script()` method.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia da src/sagemaker/processing.py, in particolare FrameworkProcessor.run() e _generate_framework_script(), quindi confronta l’analisi dell’URL CodeArtifact in sagemaker-training-toolkit modules.py. Traccia il modo in cui runproc.sh installa requirements.txt. Il lavoro è completato quando è possibile passare un ARN del repository opzionale e il job generato esegue l’autenticazione a CodeArtifact prima di installare i pacchetti privati.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
aws, python
Ambito
cloud, machine-learning
Tipo di issue
Funzionalità
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Specificata chiaramente
Idoneità per principianti
38/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.