Skip to content

Commit

Permalink
Update licenses in torchao/experimental
Browse files Browse the repository at this point in the history
Differential Revision: D61548961

Pull Request resolved: pytorch#720
  • Loading branch information
metascroy authored Aug 21, 2024
1 parent 227d4bf commit d683ba3
Show file tree
Hide file tree
Showing 42 changed files with 215 additions and 44 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

cmake_minimum_required(VERSION 3.19)
project(benchmarks)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <arm_neon.h>
#include <benchmark/benchmark.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <benchmark/benchmark.h>
#include <torchao/experimental/kernels/cpu/aarch64/linear/linear.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <benchmark/benchmark.h>
#include <torchao/experimental/kernels/cpu/aarch64/quantization/quantize.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
#!/bin/bash
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

# Call script with sh build_and_run_benchmarks.sh {BENCHAMRK}

SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
6 changes: 6 additions & 0 deletions torchao/experimental/kernels/cpu/aarch64/bitpacking/macro.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once

#define TORCHAO_ALWAYS_INLINE __attribute__((always_inline))
6 changes: 5 additions & 1 deletion torchao/experimental/kernels/cpu/aarch64/bitpacking/uint3.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
6 changes: 5 additions & 1 deletion torchao/experimental/kernels/cpu/aarch64/bitpacking/uint4.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/aarch64/bitpacking/bitpack.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/aarch64/bitpacking/bitpack.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/aarch64/bitpacking/bitpack.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/aarch64/quantization/quantize.h>
Expand Down
6 changes: 5 additions & 1 deletion torchao/experimental/kernels/cpu/aarch64/linear/linear.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/quantization/quantize.h>
#include <algorithm>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/reduction/reduction.h>
#include <cassert>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/reduction/reduction.h>
#include <cassert>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <arm_neon.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

cmake_minimum_required(VERSION 3.19)
project(tests)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
#!/bin/bash
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)
export TORCHAO_LIBRARIES=${SCRIPT_DIR}/../../../../../..
export CMAKE_OUT=/tmp/cmake-out/torch_ao/tests
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <arm_neon.h>
#include <gtest/gtest.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <arm_neon.h>
#include <gtest/gtest.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <arm_neon.h>
#include <gtest/gtest.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <arm_neon.h>
#include <gtest/gtest.h>
Expand Down
6 changes: 5 additions & 1 deletion torchao/experimental/kernels/cpu/aarch64/tests/test_utils.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/aarch64/quantization/quantize.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <gtest/gtest.h>
#include <torchao/experimental/kernels/cpu/aarch64/valpacking/valpack.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/valpacking/valpack.h>
#include <cassert>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

cmake_minimum_required(VERSION 3.19)
project(benchmarks)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <benchmark/benchmark.h>
#include <torchao/experimental/kernels/cpu/aarch64/tests/test_utils.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
#!/bin/bash
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

# Call script with sh build_and_run_benchmarks.sh {BENCHAMRK}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/macro.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

project(examples)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#pragma once
#include <torchao/experimental/kernels/cpu/linear/channelwise_8bit_activation_groupwise_lowbit_weight.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
#!/bin/bash
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.

SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)
export TORCHAO_LIBRARIES=${SCRIPT_DIR}/../../../../../..
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/tests/test_utils.h>
#include <torchao/experimental/kernels/cpu/linear/channelwise_8bit_activation_groupwise_lowbit_weight.h>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
// Copyright (c) Meta Platforms, Inc. and affiliates.
// All rights reserved.
//
// This source code is licensed under the license found in the
// LICENSE file in the root directory of this source tree.

#include <torchao/experimental/kernels/cpu/aarch64/tests/test_utils.h>
#include <torchao/experimental/kernels/cpu/linear/examples/Channelwise8BitActivationGroupwiseLowbitWeightLinearOperator.h>
Expand Down
Loading

0 comments on commit d683ba3

Please sign in to comment.