Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .github/workflows/nix-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Nix Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: meta-introspector/checkout@v4
- uses: meta-introspector/install-nix-action@v26
with:
extra_nix_config: |
experimental-features = nix-command flakes
- run: nix build --impure
- run: nix build --impure 2>&1 | tail -3
21 changes: 21 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
description = "Nix flake for CLAP";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
outputs = { self, nixpkgs }:
let
system = "x86_64-linux";
pkgs = import nixpkgs { inherit system; config.allowUnfree = true; };
in {
packages.${system}.default = pkgs.python3Packages.buildPythonPackage {
pname = "CLAP";
version = "0.1.0";
format = "pyproject";
src = ./.;
build-system = [ pkgs.python3Packages.setuptools ];
dependencies = with pkgs.python3Packages; [ torch torchaudio transformers numpy soundfile librosa torchlibrosa ftfy webdataset wandb scipy scikit-learn pandas h5py tqdm regex torchvision wget progressbar ];

pythonRelaxDeps = true;
doCheck = false;
};
};
}