1{ lib 2, buildPythonPackage 3, pythonOlder 4, fetchFromGitHub 5, pythonRelaxDepsHook 6, attrs 7, boto3 8, cloudpickle 9, google-pasta 10, numpy 11, protobuf 12, smdebug-rulesconfig 13, importlib-metadata 14, packaging 15, pandas 16, pathos 17, schema 18, pyyaml 19, jsonschema 20, platformdirs 21, tblib 22, urllib3 23, docker 24, scipy 25}: 26 27buildPythonPackage rec { 28 pname = "sagemaker"; 29 version = "2.197.0"; 30 format = "setuptools"; 31 32 disabled = pythonOlder "3.8"; 33 34 src = fetchFromGitHub { 35 owner = "aws"; 36 repo = "sagemaker-python-sdk"; 37 rev = "refs/tags/v${version}"; 38 hash = "sha256-d4HbwzgVfuo6n4FD/nl88XeQi/FPRrlq8AIV/eZz9f4="; 39 }; 40 41 nativeBuildInputs = [ 42 pythonRelaxDepsHook 43 ]; 44 45 pythonRelaxDeps = [ 46 "attrs" 47 "boto3" 48 ]; 49 50 propagatedBuildInputs = [ 51 attrs 52 boto3 53 cloudpickle 54 google-pasta 55 numpy 56 protobuf 57 smdebug-rulesconfig 58 importlib-metadata 59 packaging 60 pandas 61 pathos 62 schema 63 pyyaml 64 jsonschema 65 platformdirs 66 tblib 67 ]; 68 69 doCheck = false; # many test dependencies are not available in nixpkgs 70 71 pythonImportsCheck = [ 72 "sagemaker" 73 "sagemaker.lineage.visualizer" 74 ]; 75 76 passthru.optional-dependencies = { 77 local = [ urllib3 docker pyyaml ]; 78 scipy = [ scipy ]; 79 # feature-processor = [ pyspark sagemaker-feature-store-pyspark ]; # not available in nixpkgs 80 }; 81 82 meta = with lib; { 83 description = "Library for training and deploying machine learning models on Amazon SageMaker"; 84 homepage = "https://github.com/aws/sagemaker-python-sdk/"; 85 changelog = "https://github.com/aws/sagemaker-python-sdk/blob/v${version}/CHANGELOG.md"; 86 license = licenses.asl20; 87 maintainers = with maintainers; [ nequissimus ]; 88 }; 89}