Unverified Commit 2653f8db authored by kirillrdy's avatar kirillrdy Committed by GitHub
Browse files

python3Packages.tensordict: 0.10.0 -> 0.11.0 (#484032)

parents e03699f5 6f4fb02d
Loading
Loading
Loading
Loading
+6 −13
Original line number Diff line number Diff line
@@ -6,9 +6,6 @@
  # build-system
  poetry-core,

  # dependencies
  packaging,

  # tests
  jax,
  numpy,
@@ -16,26 +13,22 @@
  pytestCheckHook,
}:

buildPythonPackage rec {
buildPythonPackage (finalAttrs: {
  pname = "pyvers";
  version = "0.1.0";
  version = "0.2.2";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "vmoens";
    repo = "pyvers";
    tag = "v${version}";
    hash = "sha256-BUUfb0vI1r/VV5aF9gmqnXGOIWQfBJ98MrcF/IH5CEs=";
    tag = "v${finalAttrs.version}";
    hash = "sha256-VKNwhxyc1f7tyJO7JyBNELlZwVv6U2N8ye0OYFN/nmc=";
  };

  build-system = [
    poetry-core
  ];

  dependencies = [
    packaging
  ];

  pythonImportsCheck = [ "pyvers" ];

  nativeCheckInputs = [
@@ -48,8 +41,8 @@ buildPythonPackage rec {
  meta = {
    description = "Python library for dynamic dispatch based on module versions and backends";
    homepage = "https://github.com/vmoens/pyvers";
    changelog = "https://github.com/vmoens/pyvers/blob/${src.rev}/CHANGELOG.md";
    changelog = "https://github.com/vmoens/pyvers/blob/${finalAttrs.src.tag}/CHANGELOG.md";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ GaetanLepage ];
  };
}
})
+11 −6
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
  stdenv,
  buildPythonPackage,
  fetchFromGitHub,
  pythonAtLeast,

  # build-system
  pybind11,
@@ -27,16 +28,16 @@
  pytestCheckHook,
}:

buildPythonPackage rec {
buildPythonPackage (finalAttrs: {
  pname = "tensordict";
  version = "0.10.0";
  version = "0.11.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "pytorch";
    repo = "tensordict";
    tag = "v${version}";
    hash = "sha256-yxyA9BfN2hp1C3s+g2zBM2gVtckH3LV7luWw8DshFUs=";
    tag = "v${finalAttrs.version}";
    hash = "sha256-PUPDKv10Ks4B1kpgbRcnmfWFUkpFEdxMmTNztFVfdK4=";
  };

  postPatch = ''
@@ -86,6 +87,10 @@ buildPythonPackage rec {
    # hangs forever on some CPUs
    "test_map_iter_interrupt_early"
  ]
  ++ lib.optionals (pythonAtLeast "3.14") [
    # AssertionError: assert 'a string!' == 'a metadata!'
    "test_save_load_memmap"
  ]
  ++ lib.optionals stdenv.hostPlatform.isDarwin [
    # Hangs due to the use of a pool
    "test_chunksize_num_chunks"
@@ -109,9 +114,9 @@ buildPythonPackage rec {

  meta = {
    description = "Pytorch dedicated tensor container";
    changelog = "https://github.com/pytorch/tensordict/releases/tag/${src.tag}";
    changelog = "https://github.com/pytorch/tensordict/releases/tag/${finalAttrs.src.tag}";
    homepage = "https://github.com/pytorch/tensordict";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ GaetanLepage ];
  };
}
})
+20 −11
Original line number Diff line number Diff line
@@ -10,6 +10,7 @@
  numpy,
  pybind11,
  setuptools,
  setuptools-scm,
  torch,

  # dependencies
@@ -45,6 +46,7 @@
  vllm,
  # marl
  pettingzoo,
  vmas,
  # offline-data
  h5py,
  huggingface-hub,
@@ -71,16 +73,16 @@
  scipy,
}:

buildPythonPackage rec {
buildPythonPackage (finalAttrs: {
  pname = "torchrl";
  version = "0.10.1";
  version = "0.11.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "pytorch";
    repo = "rl";
    tag = "v${version}";
    hash = "sha256-Vd/w11P4NVrx2xki+VYlXQaM8F+vpdokke8ZAHg6h0Q=";
    tag = "v${finalAttrs.version}";
    hash = "sha256-Ae1zhc3lESCsuAJbbjrT5Vv0zTIiiBw9HBtKwWsbVzc=";
  };

  postPatch = ''
@@ -94,6 +96,7 @@ buildPythonPackage rec {
    numpy
    pybind11
    setuptools
    setuptools-scm
    torch
  ];
  dontUseCmakeConfigure = true;
@@ -139,7 +142,7 @@ buildPythonPackage rec {
    marl = [
      # dm-meltingpot (unpackaged)
      pettingzoo
      # vmas (unpackaged)
      vmas
    ];
    offline-data = [
      h5py
@@ -155,6 +158,9 @@ buildPythonPackage rec {
    open-spiel = [
      # open-spiel (unpackaged)
    ];
    procgen = [
      # procgen (unpackaged)
    ];
    rendering = [ moviepy ];
    replay-buffer = [ torch ];
    utils = [
@@ -191,10 +197,10 @@ buildPythonPackage rec {
    scipy
    torchvision
  ]
  ++ optional-dependencies.atari
  ++ optional-dependencies.gym-continuous
  ++ optional-dependencies.llm
  ++ optional-dependencies.rendering;
  ++ finalAttrs.passthru.optional-dependencies.atari
  ++ finalAttrs.passthru.optional-dependencies.gym-continuous
  ++ finalAttrs.passthru.optional-dependencies.llm
  ++ finalAttrs.passthru.optional-dependencies.rendering;

  disabledTests = [
    # Require network
@@ -284,13 +290,16 @@ buildPythonPackage rec {
    # which is not the same as the test file we want to collect:
    #   /build/source/test/smoke_test.py
    "test/llm"

    # Hang indefinitely
    "test/services/test_services.py"
  ];

  meta = {
    description = "Modular, primitive-first, python-first PyTorch library for Reinforcement Learning";
    homepage = "https://github.com/pytorch/rl";
    changelog = "https://github.com/pytorch/rl/releases/tag/v${version}";
    changelog = "https://github.com/pytorch/rl/releases/tag/${finalAttrs.src.tag}";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ GaetanLepage ];
  };
}
})