diff --git a/android/Torchchat/app/src/test/java/org/pytorch/torchchat/ExampleUnitTest.java b/android/Torchchat/app/src/test/java/org/pytorch/torchchat/ExampleUnitTest.java index 2c2fbc93e..8fbffcf35 100644 --- a/android/Torchchat/app/src/test/java/org/pytorch/torchchat/ExampleUnitTest.java +++ b/android/Torchchat/app/src/test/java/org/pytorch/torchchat/ExampleUnitTest.java @@ -1,3 +1,11 @@ +/* + * Copyright (c) Meta Platforms, Inc. and affiliates. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. + */ + package org.pytorch.torchchat; import org.junit.Test; diff --git a/browser/browser.py b/browser/browser.py index 613146d8b..5c3fca797 100644 --- a/browser/browser.py +++ b/browser/browser.py @@ -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. + import subprocess import sys diff --git a/runner/aoti.cmake b/runner/aoti.cmake index 2ae9a4079..156e9bcce 100644 --- a/runner/aoti.cmake +++ b/runner/aoti.cmake @@ -1,3 +1,10 @@ +#!/bin/bash +# Copyright (c) Meta Platforms, Inc. and affiliates. +# All rights reserved. +# +# This source code is licensed under the BSD-style license found in the +# LICENSE file in the root directory of this source tree. + cmake_minimum_required(VERSION 3.24) set(CMAKE_CXX_STANDARD 17) IF(DEFINED ENV{TORCHCHAT_ROOT}) diff --git a/runner/et.cmake b/runner/et.cmake index 6b233ae9c..7fc16b1f2 100644 --- a/runner/et.cmake +++ b/runner/et.cmake @@ -1,3 +1,10 @@ +#!/bin/bash +# Copyright (c) Meta Platforms, Inc. and affiliates. +# All rights reserved. +# +# This source code is licensed under the BSD-style license found in the +# LICENSE file in the root directory of this source tree. + cmake_minimum_required(VERSION 3.24) set(CMAKE_CXX_STANDARD 17) diff --git a/scripts/prepare.sh b/scripts/prepare.sh index c3a74e6eb..b3bec8f14 100755 --- a/scripts/prepare.sh +++ b/scripts/prepare.sh @@ -1 +1,7 @@ -python3 scripts/download.py --repo-id $1 && python3 scripts/convert_hf_checkpoint.py --checkpoint-dir checkpoints/$1 +# 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. + +python3 scripts/download.py --repo-id $1 && python3 scripts/convert_hf_checkpoint.py --checkpoint-dir checkpoints/$1 diff --git a/scripts/test_flow.sh b/scripts/test_flow.sh index 9cc25b186..1813612cd 100755 --- a/scripts/test_flow.sh +++ b/scripts/test_flow.sh @@ -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. + export MODEL_REPO=meta-llama/Llama-2-7b-chat-hf rm -r checkpoints/$MODEL_REPO python3 scripts/download.py --repo-id $MODEL_REPO diff --git a/unsupported/llama2.c/runner-et/run.cpp b/unsupported/llama2.c/runner-et/run.cpp index 64d38fa0a..a3fa6996d 100644 --- a/unsupported/llama2.c/runner-et/run.cpp +++ b/unsupported/llama2.c/runner-et/run.cpp @@ -1,3 +1,11 @@ +/* +* Copyright (c) Meta Platforms, Inc. and affiliates. + * All rights reserved. + * + * This source code is licensed under the BSD-style license found in the + * LICENSE file in the root directory of this source tree. +*/ + /* Inference for Llama-2 Transformer model in pure C */ /* this uses the same logic regardless of AOTI OR ET */ /* but requires different data types - ATen vs ETen */ diff --git a/utils/measure_time.py b/utils/measure_time.py index 874061e46..89ec2d091 100644 --- a/utils/measure_time.py +++ b/utils/measure_time.py @@ -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. + from time import perf_counter from typing import Optional