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
2 changes: 0 additions & 2 deletions .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

name: Static Analysis

Expand Down
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

venv
__pycache__
.DS_STORE
Expand Down
6 changes: 6 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

[submodule "open_flamingo"]
path = open_flamingo
url = https://github.com/mlfoundations/open_flamingo.git
Expand Down
2 changes: 0 additions & 2 deletions .linkspector.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

dirs:
- .
Expand Down
9 changes: 9 additions & 0 deletions .reuse/templates/opentslm.jinja2
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
This source file is part of the OpenTSLM open-source project

{% for line in copyright_lines %}
{{ line }}
{% endfor %}

{% for expr in spdx_expressions %}
SPDX-License-Identifier: {{ expr }}
{% endfor %}
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,19 @@ For researchers and project partners interested in collaboration opportunities,

This project is licensed under the MIT License.

We use the [REUSE specification](https://reuse.software/spec/) to ensure consistent and machine-readable licensing across the repository.

To add or update license headers, run:

```bash
reuse annotate --recursive \
--template opentslm \
--copyright "Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)" \
--license MIT \
--skip-unrecognised \
.
```

<div align="left">
<img src="assets/stanford_biodesign_logo.png" alt="Stanford Biodesign" height="90">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img src="assets/CDHI_white.svg" alt="ETH Centre for Digital Health Interventions" height="90">
Expand Down
2 changes: 1 addition & 1 deletion REUSE.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
version = 1

[[annotations]]
path = ["assets/**", "data/**", "**/*.png", "**/*.jpg", "**/*.jpeg", "**/*.gif", "**/*.svg", "**/*.ico", "**/*.pt", "**/*.jsonl", "**/*.json", ".gitignore", ".gitmodules", "**/.gitignore", "LICENSE.md", "requirements.txt"]
path = ["data/**"]
SPDX-FileCopyrightText = "2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)"
SPDX-License-Identifier = "MIT"
2 changes: 0 additions & 2 deletions __init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
5 changes: 5 additions & 0 deletions assets/ASL_Logo2.svg.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/ASLwhite.svg.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/CDHI_white.svg.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/cdhi_logo.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/ecg_rationale.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/eth_cdhi_logo.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/eth_logo.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/har_rationale.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/m4_caption.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/schematic_overview_2.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/schematic_overview_3.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/sleep_rationale.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
5 changes: 5 additions & 0 deletions assets/stanford_biodesign_logo.png.license
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This source file is part of the OpenTSLM open-source project

SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)

SPDX-License-Identifier: MIT
2 changes: 0 additions & 2 deletions create_doctor_eval_dataset.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Script to create doctor evaluation dataset with correct model predictions.
This script extracts ECG-QA templates with correct model outputs from llama3b_flamingo_predictions.jsonl
Expand Down
2 changes: 0 additions & 2 deletions curriculum_learning.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import sys
import os
Expand Down
6 changes: 6 additions & 0 deletions data/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

*.csv
*.json
*.jsonl
Expand Down
6 changes: 6 additions & 0 deletions demo/huggingface/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

data
2 changes: 0 additions & 2 deletions demo/huggingface/01_test_hf_tsqa.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Demo script for testing TSQA (Time Series Question Answering) model from HuggingFace.

Expand Down
2 changes: 0 additions & 2 deletions demo/huggingface/02_test_hf_m4.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Demo script for testing M4 (Time Series Captioning) model from HuggingFace.

Expand Down
2 changes: 0 additions & 2 deletions demo/huggingface/03_test_hf_har_cot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Demo script for testing HAR CoT (Human Activity Recognition Chain-of-Thought) model from HuggingFace.

Expand Down
2 changes: 0 additions & 2 deletions demo/huggingface/04_test_hf_sleep_cot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Demo script for testing Sleep CoT (Sleep Stage Classification Chain-of-Thought) model from HuggingFace.

Expand Down
2 changes: 0 additions & 2 deletions demo/huggingface/05_test_hf_ecg_qa_cot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
"""
Demo script for testing ECG QA CoT (ECG Question Answering Chain-of-Thought) model from HuggingFace.

Expand Down
6 changes: 6 additions & 0 deletions evaluation/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

*.jsonl
2 changes: 0 additions & 2 deletions evaluation/baseline/common_evaluator.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import json
import os
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/common_evaluator_plot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import os
import io
Expand Down
3 changes: 1 addition & 2 deletions evaluation/baseline/eval.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
#!/usr/bin/env bash
#

# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

set -euo pipefail

Expand Down
4 changes: 4 additions & 0 deletions evaluation/baseline/eval_remaining.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
#!/usr/bin/env bash

# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT

python evaluate_tsqa.py "google/gemma-3-270m"
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_all.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

from typing import Dict, Any, Callable
from common_evaluator import CommonEvaluator
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_ecg_qa.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_ecg_qa_plot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_har.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_har_plot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_pamap.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
2 changes: 0 additions & 2 deletions evaluation/baseline/evaluate_sleep_cot.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
#
# This source file is part of the OpenTSLM open-source project
#
# SPDX-FileCopyrightText: 2025 Stanford University, ETH Zurich, and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#

import re
import sys
Expand Down
Loading