-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflake.nix
95 lines (83 loc) · 3.21 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
{
description = "Agent Learning Framework Development Environment";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
utils.url = "github:numtide/flake-utils";
ml-pkgs.url = "github:nixvital/ml-pkgs";
ml-pkgs.inputs.nixpkgs.follows = "nixpkgs";
ml-pkgs.inputs.utils.follows = "utils";
# Normally we use alf from a commit. In case you want to use a local alf
# repo, commnet the following line and uncomment the line below it.
alf.url = "github:HorizonRobotics/alf/PR/breakds/alf_packaged_new";
# alf.url = "git+file:///home/breakds/projects/alf";
alf.inputs.nixpkgs.follows = "nixpkgs";
alf.inputs.ml-pkgs.follows = "ml-pkgs";
alf.inputs.utils.follows = "utils";
tensor-splines.url = "git+ssh://[email protected]/HorizonRobotics/tensor-splines?ref=main";
tensor-splines.inputs.nixpkgs.follows = "nixpkgs";
tensor-splines.inputs.utils.follows = "utils";
tensor-splines.inputs.ml-pkgs.follows = "ml-pkgs";
sagittarius-sdk.url = "git+ssh://[email protected]/HorizonRoboticsInternal/sagittarius-sdk";
sagittarius-sdk.inputs.nixpkgs.follows = "nixpkgs";
sagittarius-sdk.inputs.utils.follows = "utils";
kincpp.url = "git+ssh://[email protected]/HorizonRoboticsInternal/kincpp?ref=main";
kincpp.inputs.nixpkgs.follows = "nixpkgs";
kincpp.inputs.utils.follows = "utils";
relaxed-ik.url = "github:breakds/relaxed_ik_core";
relaxed-ik.inputs.nixpkgs.follows = "nixpkgs";
relaxed-ik.inputs.utils.follows = "utils";
};
outputs = { self, nixpkgs, alf, ... }@inputs: {
overlays = {
hobot = nixpkgs.lib.composeManyExtensions [
alf.overlays.default
inputs.ml-pkgs.overlays.jax-family
inputs.ml-pkgs.overlays.math
inputs.sagittarius-sdk.overlays.default
inputs.kincpp.overlays.default
inputs.relaxed-ik.overlays.default
(final: prev: {
stream-zed = final.callPackage ./nix/pkgs/stream-zed {};
pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
(python-final: python-prev: {
opencv4 = python-prev.opencv4.override {
enableCuda = false;
enableGtk3 = true;
};
})
];
})
];
};
} // inputs.utils.lib.eachSystem [
"x86_64-linux"
] (system:
let pkgs-hobot = import nixpkgs {
inherit system;
config = {
allowUnfree = true;
cudaSupport = true;
cudaCapabilities = [ "7.5" "8.6" ];
cudaForwardCompat = true;
};
overlays = [
self.overlays.hobot
];
};
in {
devShells = {
hobot-dev = pkgs-hobot.callPackage ./nix/pkgs/hobot-dev-shell {};
};
packages = {
# The following are the docker images for Hobot runtime. They are
# currently under active development.
hobot-runtime-legacy = pkgs-hobot.callPackage ./nix/pkgs/hobot-runtime {
useLegacyMujoco = true;
};
hobot-runtime = pkgs-hobot.callPackage ./nix/pkgs/hobot-runtime {
useLegacyMujoco = false;
};
hobot-docker = pkgs-hobot.callPackage ./nix/dockers/hobot.nix {};
};
});
}