python311Packages.tensorflow-probability: 0.21.0 -> 0.24.0

Diff:
https://github.com/tensorflow/probability/compare/v0.21.0...v0.24.0

Changelog:
https://github.com/tensorflow/probability/releases/tag/v0.24.0
This commit is contained in:
Gaetan Lepage 2024-08-25 11:25:18 +02:00
parent d6106f996d
commit 62b7668763

View File

@ -1,34 +1,45 @@
{ {
lib, lib,
stdenv, stdenv,
fetchFromGitHub,
bazel_6, # bazel wheel
buildBazelPackage, buildBazelPackage,
buildPythonPackage, fetchFromGitHub,
cctools,
# nativeBuildInputs
python, python,
setuptools, setuptools,
wheel, wheel,
absl-py, absl-py,
tensorflow,
six, bazel_6,
numpy, cctools,
dm-tree,
keras, # python package
decorator, buildPythonPackage,
# dependencies
cloudpickle, cloudpickle,
decorator,
dm-tree,
gast, gast,
keras,
numpy,
six,
tensorflow,
# tests
hypothesis, hypothesis,
scipy,
pandas,
mpmath,
matplotlib, matplotlib,
mock, mock,
mpmath,
pandas,
pytest, pytest,
scipy,
}: }:
let let
version = "0.21.0"; version = "0.24.0";
pname = "tensorflow-probability"; pname = "tensorflow-probability";
# first build all binaries and generate setup.py using bazel # first build all binaries and generate setup.py using bazel
@ -38,15 +49,15 @@ let
owner = "tensorflow"; owner = "tensorflow";
repo = "probability"; repo = "probability";
rev = "refs/tags/v${version}"; rev = "refs/tags/v${version}";
hash = "sha256-DsJd1E5n86xNS7Ci0DXxoUxQ9jH8OwTZq2UuLlQtMUU="; hash = "sha256-V6aw4NtGOHlvcbgLWMH29x81eck1PyzV93ANelvpL4c=";
}; };
nativeBuildInputs = [ nativeBuildInputs = [
absl-py
# needed to create the output wheel in installPhase # needed to create the output wheel in installPhase
python python
setuptools setuptools
wheel
absl-py
tensorflow tensorflow
wheel
]; ];
bazel = bazel_6; bazel = bazel_6;
@ -83,27 +94,27 @@ buildPythonPackage {
src = bazel-wheel; src = bazel-wheel;
propagatedBuildInputs = [ dependencies = [
tensorflow
six
numpy
decorator
cloudpickle cloudpickle
gast decorator
dm-tree dm-tree
gast
keras keras
numpy
six
tensorflow
]; ];
# Listed here: # Listed here:
# https://github.com/tensorflow/probability/blob/f3777158691787d3658b5e80883fe1a933d48989/testing/dependency_install_lib.sh#L83 # https://github.com/tensorflow/probability/blob/f3777158691787d3658b5e80883fe1a933d48989/testing/dependency_install_lib.sh#L83
nativeCheckInputs = [ nativeCheckInputs = [
hypothesis hypothesis
pytest
scipy
pandas
mpmath
matplotlib matplotlib
mock mock
mpmath
pandas
pytest
scipy
]; ];
# Ideally, we run unit tests with pytest, but in checkPhase, only the Bazel-build wheel is available. # Ideally, we run unit tests with pytest, but in checkPhase, only the Bazel-build wheel is available.
@ -114,10 +125,11 @@ buildPythonPackage {
# sanity check # sanity check
pythonImportsCheck = [ "tensorflow_probability" ]; pythonImportsCheck = [ "tensorflow_probability" ];
meta = with lib; { meta = {
description = "Library for probabilistic reasoning and statistical analysis"; description = "Library for probabilistic reasoning and statistical analysis";
homepage = "https://www.tensorflow.org/probability/"; homepage = "https://www.tensorflow.org/probability/";
license = licenses.asl20; changelog = "https://github.com/tensorflow/probability/releases/tag/v${version}";
maintainers = with maintainers; [ GaetanLepage ]; license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ GaetanLepage ];
}; };
} }