Unverified Commit e489ad7a authored by Russell Bryant's avatar Russell Bryant Committed by GitHub
Browse files

[Misc] Add SPDX-License-Identifier headers to python source files (#12628)

- **Add SPDX license headers to python source files**
- **Check for SPDX headers using pre-commit**

commit 9d7ef44c3cfb72ca4c32e1c677d99259d10d4745
Author: Russell Bryant <rbryant@redhat.com>
Date:   Fri Jan 31 14:18:24 2025 -0500

    Add SPDX license headers to python source files
    
This commit adds SPDX license headers to python source files as
recommended to
the project by the Linux Foundation. These headers provide a concise way
that is
both human and machine readable for communicating license information
for each
source file. It helps avoid any ambiguity about the license of the code
and can
    also be easily used by tools to help manage license compliance.
    
The Linux Foundation runs license scans against the codebase to help
ensure
    we are in compliance with the licenses of the code we use, including
dependencies. Having these headers in place helps that tool do its job.
    
    More information can be found on ...
parent f256ebe4
# SPDX-License-Identifier: Apache-2.0
"""Tests for the machete kernel. """Tests for the machete kernel.
Run `pytest tests/kernels/test_machete_mm.py`. Run `pytest tests/kernels/test_machete_mm.py`.
......
# SPDX-License-Identifier: Apache-2.0
import pytest import pytest
import torch import torch
import torch.nn.functional as F import torch.nn.functional as F
......
# SPDX-License-Identifier: Apache-2.0
"""Tests for the marlin kernel. """Tests for the marlin kernel.
Run `pytest tests/kernels/marlin/test_marlin_gemm.py`. Run `pytest tests/kernels/marlin/test_marlin_gemm.py`.
......
# SPDX-License-Identifier: Apache-2.0
""" """
Test: Test:
......
# SPDX-License-Identifier: Apache-2.0
"""Tests for the MOE layers. """Tests for the MOE layers.
Run `pytest tests/kernels/test_moe.py`. Run `pytest tests/kernels/test_moe.py`.
......
# SPDX-License-Identifier: Apache-2.0
import pytest import pytest
import torch import torch
......
# SPDX-License-Identifier: Apache-2.0
from itertools import accumulate, product from itertools import accumulate, product
from typing import Dict, List, Optional from typing import Dict, List, Optional
......
# SPDX-License-Identifier: Apache-2.0
import math import math
import random import random
import time import time
......
# SPDX-License-Identifier: Apache-2.0
""" """
Tests for miscellaneous utilities Tests for miscellaneous utilities
""" """
......
# SPDX-License-Identifier: Apache-2.0
import pytest import pytest
import torch import torch
......
# SPDX-License-Identifier: Apache-2.0
"""Tests for the triton_scaled_mm kernel """Tests for the triton_scaled_mm kernel
Run `pytest tests/kernels/test_triton_scaled_mm.py`. Run `pytest tests/kernels/test_triton_scaled_mm.py`.
......
# SPDX-License-Identifier: Apache-2.0
""" """
Tests for miscellaneous utilities Tests for miscellaneous utilities
""" """
......
# SPDX-License-Identifier: Apache-2.0
"""Kernel test utils""" """Kernel test utils"""
import itertools import itertools
......
# SPDX-License-Identifier: Apache-2.0
import os import os
import subprocess import subprocess
import sys import sys
......
# SPDX-License-Identifier: Apache-2.0
import subprocess import subprocess
import sys import sys
......
# SPDX-License-Identifier: Apache-2.0
import os import os
import random import random
......
# SPDX-License-Identifier: Apache-2.0
import os import os
import time import time
from typing import List from typing import List
......
# SPDX-License-Identifier: Apache-2.0
import tempfile import tempfile
from collections import OrderedDict from collections import OrderedDict
from typing import Dict, List, TypedDict from typing import Dict, List, TypedDict
......
# SPDX-License-Identifier: Apache-2.0
# ruff: noqa # ruff: noqa
"""This file contains a dictionary of prompts and golden responses.""" """This file contains a dictionary of prompts and golden responses."""
......
# SPDX-License-Identifier: Apache-2.0
from typing import List from typing import List
import pytest import pytest
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment