Skip to content
Merged
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
51 changes: 51 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: CI

on:
push:
branches: [main, develop]
pull_request:
branches: [main, develop]

jobs:
build-and-test:
name: Build and Test
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v5

- name: Install ROOT
run: |
ROOT_URL="https://root.cern/download/root_v6.34.06.Linux-ubuntu24.04-x86_64-gcc13.3.tar.gz"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see that you updated to Ubuntu 24.04 , but not to root 6.36 version? There is a root_v6.36.00.Linux-ubuntu24.04-x86_64-gcc13.3.tar.gz file you can download

wget -O root.tar.gz $ROOT_URL
tar -xzf root.tar.gz -C /opt/
echo "/opt/root/bin" >> $GITHUB_PATH

- name: Install build dependencies
run: |
sudo apt-get update
sudo apt-get install -y libvdt-dev libtbb-dev
Comment on lines +26 to +27

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sudo not needed I believe, since Github runner workflows are on an admin account by default

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Run apt-get update Reading package lists... E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied) E: Unable to lock directory /var/lib/apt/lists/ Error: Process completed with exit code 100.
getting permission issues if not using sudo


- name: Configure CMake
run: |
source thisroot.sh
mkdir build
cd build
cmake .. \
-DCMAKE_BUILD_TYPE=Release \
-DRAMTOOLS_BUILD_TESTS=ON \
-DRAMTOOLS_BUILD_TOOLS=ON \
-DRAMTOOLS_BUILD_BENCHMARKS=OFF

- name: Build
run: |
source thisroot.sh
cd build
cmake --build . --config Release -j $(nproc)

- name: Run tests
run: |
source thisroot.sh
cd build
ctest --output-on-failure --build-config Release

4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ tmp/
*.fq
*.bk
*.rootix
*.sam
build/
cmake-build-*/
Build/
Expand All @@ -25,4 +24,5 @@ Testing/
.vscode/
docs/html/
docs/latex/
html/
html/

2 changes: 1 addition & 1 deletion src/ramcore/SamToNTuple.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ void samtoramntuple(const char *datafile,

auto model = RAMNTupleRecord::MakeModel();

ROOT::RNTupleWriteOptions writeOptions;
ROOT::Experimental::RNTupleWriteOptions writeOptions;
writeOptions.SetCompression(compression_algorithm);
writeOptions.SetMaxUnzippedPageSize(64000);

Expand Down
6 changes: 3 additions & 3 deletions src/rntuple/RAMNTupleRecord.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ void RAMNTupleRecord::WriteAllRefs(TFile &file)
auto rnameField = metaModel->MakeField<std::vector<std::string>>("rname_refs");
auto rnextField = metaModel->MakeField<std::vector<std::string>>("rnext_refs");

ROOT::RNTupleWriteOptions writeOptions;
RNTupleWriteOptions writeOptions;
writeOptions.SetCompression(505);

auto metaWriter = RNTupleWriter::Append(std::move(metaModel), "METADATA", file, writeOptions);
Expand Down Expand Up @@ -256,7 +256,7 @@ void RAMNTupleRecord::WriteIndex(TFile &file)
auto indexModel = RNTupleModel::Create();
auto indexField = indexModel->MakeField<std::vector<RAMNTupleIndex::IndexEntry>>("index_entries");

ROOT::RNTupleWriteOptions writeOptions;
RNTupleWriteOptions writeOptions;
writeOptions.SetCompression(505);

auto indexWriter = RNTupleWriter::Append(std::move(indexModel), "INDEX", file, writeOptions);
Expand Down Expand Up @@ -530,7 +530,7 @@ void RAMNTupleConverter::ConvertSAMToRAMNTuple(const std::string &sam_file, cons

auto model = RAMNTupleRecord::MakeModel();

ROOT::RNTupleWriteOptions writeOptions;
RNTupleWriteOptions writeOptions;
writeOptions.SetCompression(505); // ZSTD level 5

auto writer = RNTupleWriter::Append(std::move(model), "RAM", *file, writeOptions);
Expand Down