From 6798507a2907c3aecfd9622ff3ec392af30e6d0e Mon Sep 17 00:00:00 2001 From: YanxuanLiu <104543031+YanxuanLiu@users.noreply.github.com> Date: Wed, 27 Nov 2024 08:43:35 +0800 Subject: [PATCH] add license header and check workflow (#473) Signed-off-by: YanxuanLiu --- .github/workflows/license-header-check.yml | 54 +++++++++++++++++++ dockerfile/gpu_executor_template.yaml | 14 +++++ .../xgboost-examples/csp/databricks/init.sh | 14 +++++ .../models_config/fashion_mnist/config.pbtxt | 14 +++++ .../models_config/housing_model/config.pbtxt | 14 +++++ .../Spark-DL/dl_inference/requirements.txt | 14 +++++ .../models_config/mnist_model/config.pbtxt | 14 +++++ .../models_config/resnet50/config.pbtxt | 14 +++++ .../Spark-DL/dl_inference/tf_requirements.txt | 14 +++++ .../dl_inference/torch_requirements.txt | 14 +++++ .../agaricus/python/com/__init__.py | 14 +++++ .../agaricus/python/com/nvidia/__init__.py | 14 +++++ .../python/com/nvidia/spark/__init__.py | 14 +++++ .../com/nvidia/spark/examples/__init__.py | 14 +++++ .../spark/examples/agaricus/__init__.py | 14 +++++ .../aggregator/assembly/assembly-no-scala.xml | 14 +++++ .../mortgage/python/com/__init__.py | 14 +++++ .../mortgage/python/com/nvidia/__init__.py | 14 +++++ .../python/com/nvidia/spark/__init__.py | 14 +++++ .../com/nvidia/spark/examples/__init__.py | 14 +++++ .../spark/examples/mortgage/__init__.py | 14 +++++ .../XGBoost-Examples/pack_pyspark_example.sh | 14 +++++ .../taxi/python/com/__init__.py | 14 +++++ .../taxi/python/com/nvidia/__init__.py | 14 +++++ .../taxi/python/com/nvidia/spark/__init__.py | 14 +++++ .../com/nvidia/spark/examples/__init__.py | 14 +++++ .../nvidia/spark/examples/taxi/__init__.py | 14 +++++ .../utility/python/com/__init__.py | 14 +++++ .../utility/python/com/nvidia/__init__.py | 14 +++++ .../python/com/nvidia/spark/__init__.py | 14 +++++ .../com/nvidia/spark/examples/__init__.py | 14 +++++ .../nvidia/spark/examples/utility/__init__.py | 14 +++++ scripts/building/python_build.sh | 14 +++++ scripts/encoding-sample/repartition.py | 14 +++++ scripts/encoding-sample/run.sh | 14 +++++ scripts/encoding-sample/truncate-model.py | 14 +++++ scripts/encoding/python/com/__init__.py | 14 +++++ .../encoding/python/com/nvidia/__init__.py | 14 +++++ .../python/com/nvidia/spark/__init__.py | 14 +++++ .../com/nvidia/spark/encoding/__init__.py | 14 +++++ .../nvidia/spark/encoding/criteo/__init__.py | 14 +++++ .../nvidia/spark/encoding/utility/__init__.py | 14 +++++ 42 files changed, 628 insertions(+) create mode 100644 .github/workflows/license-header-check.yml diff --git a/.github/workflows/license-header-check.yml b/.github/workflows/license-header-check.yml new file mode 100644 index 000000000..a2347a0c1 --- /dev/null +++ b/.github/workflows/license-header-check.yml @@ -0,0 +1,54 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# A workflow to check copyright/license header +name: license header check + +on: + pull_request: + types: [opened, synchronize, reopened] + +jobs: + license-header-check: + runs-on: ubuntu-latest + if: "!contains(github.event.pull_request.title, '[bot]')" + steps: + - name: Get checkout depth + run: | + echo "PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 10 ))" >> $GITHUB_ENV + + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: ${{ env.PR_FETCH_DEPTH }} + + - name: license-header-check + uses: NVIDIA/spark-rapids-common/license-header-check@main + with: + included_file_patterns: | + *.sh, + *.java, + *.py, + *.pbtxt, + *Dockerfile*, + *Jenkinsfile*, + *.yml, + *.yaml, + *.cpp, + *.hpp, + *.txt, + *.cu, + *.scala, + *.ini, + *.xml diff --git a/dockerfile/gpu_executor_template.yaml b/dockerfile/gpu_executor_template.yaml index 35d2f39e0..6784e590e 100644 --- a/dockerfile/gpu_executor_template.yaml +++ b/dockerfile/gpu_executor_template.yaml @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + apiVersion: v1 kind: Pod spec: diff --git a/docs/get-started/xgboost-examples/csp/databricks/init.sh b/docs/get-started/xgboost-examples/csp/databricks/init.sh index fc415b2dd..b9302f1ca 100644 --- a/docs/get-started/xgboost-examples/csp/databricks/init.sh +++ b/docs/get-started/xgboost-examples/csp/databricks/init.sh @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + sudo rm -f /databricks/jars/spark--maven-trees--ml--10.x--xgboost-gpu--ml.dmlc--xgboost4j-gpu_2.12--ml.dmlc__xgboost4j-gpu_2.12__1.5.2.jar sudo rm -f /databricks/jars/spark--maven-trees--ml--10.x--xgboost-gpu--ml.dmlc--xgboost4j-spark-gpu_2.12--ml.dmlc__xgboost4j-spark-gpu_2.12__1.5.2.jar diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/fashion_mnist/config.pbtxt b/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/fashion_mnist/config.pbtxt index 3554196f9..d98b2a110 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/fashion_mnist/config.pbtxt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/fashion_mnist/config.pbtxt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + platform: "pytorch_libtorch" max_batch_size: 8192 input [ diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/housing_model/config.pbtxt b/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/housing_model/config.pbtxt index 794ffd37e..64deefca6 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/housing_model/config.pbtxt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/pytorch/models_config/housing_model/config.pbtxt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + platform: "pytorch_libtorch" max_batch_size: 8192 input [ diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/requirements.txt b/examples/ML+DL-Examples/Spark-DL/dl_inference/requirements.txt index abd6ad089..f30f172c0 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/requirements.txt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/requirements.txt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + numpy pandas matplotlib diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/mnist_model/config.pbtxt b/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/mnist_model/config.pbtxt index 76a1437eb..cc9172f45 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/mnist_model/config.pbtxt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/mnist_model/config.pbtxt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + platform: "tensorflow_savedmodel" max_batch_size: 8192 diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/resnet50/config.pbtxt b/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/resnet50/config.pbtxt index 76a1437eb..cc9172f45 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/resnet50/config.pbtxt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/tensorflow/models_config/resnet50/config.pbtxt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + platform: "tensorflow_savedmodel" max_batch_size: 8192 diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/tf_requirements.txt b/examples/ML+DL-Examples/Spark-DL/dl_inference/tf_requirements.txt index b78561bd8..92bba846d 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/tf_requirements.txt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/tf_requirements.txt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + -r requirements.txt tensorflow[and-cuda] tf-keras \ No newline at end of file diff --git a/examples/ML+DL-Examples/Spark-DL/dl_inference/torch_requirements.txt b/examples/ML+DL-Examples/Spark-DL/dl_inference/torch_requirements.txt index 0f73b9105..5f3b90173 100644 --- a/examples/ML+DL-Examples/Spark-DL/dl_inference/torch_requirements.txt +++ b/examples/ML+DL-Examples/Spark-DL/dl_inference/torch_requirements.txt @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + -r requirements.txt torch torchvision diff --git a/examples/XGBoost-Examples/agaricus/python/com/__init__.py b/examples/XGBoost-Examples/agaricus/python/com/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/agaricus/python/com/__init__.py +++ b/examples/XGBoost-Examples/agaricus/python/com/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/agaricus/python/com/nvidia/__init__.py b/examples/XGBoost-Examples/agaricus/python/com/nvidia/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/agaricus/python/com/nvidia/__init__.py +++ b/examples/XGBoost-Examples/agaricus/python/com/nvidia/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/__init__.py b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/__init__.py +++ b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/__init__.py b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/__init__.py +++ b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/agaricus/__init__.py b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/agaricus/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/agaricus/__init__.py +++ b/examples/XGBoost-Examples/agaricus/python/com/nvidia/spark/examples/agaricus/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/aggregator/assembly/assembly-no-scala.xml b/examples/XGBoost-Examples/aggregator/assembly/assembly-no-scala.xml index fd18210e5..fe4db9da7 100644 --- a/examples/XGBoost-Examples/aggregator/assembly/assembly-no-scala.xml +++ b/examples/XGBoost-Examples/aggregator/assembly/assembly-no-scala.xml @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/mortgage/python/com/__init__.py b/examples/XGBoost-Examples/mortgage/python/com/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/mortgage/python/com/__init__.py +++ b/examples/XGBoost-Examples/mortgage/python/com/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/mortgage/python/com/nvidia/__init__.py b/examples/XGBoost-Examples/mortgage/python/com/nvidia/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/mortgage/python/com/nvidia/__init__.py +++ b/examples/XGBoost-Examples/mortgage/python/com/nvidia/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/__init__.py b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/__init__.py +++ b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/__init__.py b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/__init__.py +++ b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/mortgage/__init__.py b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/mortgage/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/mortgage/__init__.py +++ b/examples/XGBoost-Examples/mortgage/python/com/nvidia/spark/examples/mortgage/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/pack_pyspark_example.sh b/examples/XGBoost-Examples/pack_pyspark_example.sh index e446d27da..5f7564b2b 100755 --- a/examples/XGBoost-Examples/pack_pyspark_example.sh +++ b/examples/XGBoost-Examples/pack_pyspark_example.sh @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + # Follow these steps to package the Python zip file rm -fr samples.zip cd agaricus/python ; zip -r ../../samples.zip com ; cd ../.. diff --git a/examples/XGBoost-Examples/taxi/python/com/__init__.py b/examples/XGBoost-Examples/taxi/python/com/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/taxi/python/com/__init__.py +++ b/examples/XGBoost-Examples/taxi/python/com/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/taxi/python/com/nvidia/__init__.py b/examples/XGBoost-Examples/taxi/python/com/nvidia/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/taxi/python/com/nvidia/__init__.py +++ b/examples/XGBoost-Examples/taxi/python/com/nvidia/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/__init__.py b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/__init__.py +++ b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/__init__.py b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/__init__.py +++ b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/taxi/__init__.py b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/taxi/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/taxi/__init__.py +++ b/examples/XGBoost-Examples/taxi/python/com/nvidia/spark/examples/taxi/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/utility/python/com/__init__.py b/examples/XGBoost-Examples/utility/python/com/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/utility/python/com/__init__.py +++ b/examples/XGBoost-Examples/utility/python/com/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/utility/python/com/nvidia/__init__.py b/examples/XGBoost-Examples/utility/python/com/nvidia/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/utility/python/com/nvidia/__init__.py +++ b/examples/XGBoost-Examples/utility/python/com/nvidia/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/__init__.py b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/__init__.py +++ b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/__init__.py b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/__init__.py +++ b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/utility/__init__.py b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/utility/__init__.py index e69de29bb..0f6ef8237 100644 --- a/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/utility/__init__.py +++ b/examples/XGBoost-Examples/utility/python/com/nvidia/spark/examples/utility/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/building/python_build.sh b/scripts/building/python_build.sh index 033fa0bdb..78e34908d 100644 --- a/scripts/building/python_build.sh +++ b/scripts/building/python_build.sh @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + # Follow these steps to package the Python zip file cd ../../examples/XGBoost-Examples cd agaricus/python ; zip -r ../../samples.zip com ; cd ../.. diff --git a/scripts/encoding-sample/repartition.py b/scripts/encoding-sample/repartition.py index b9492ed6b..af53380db 100644 --- a/scripts/encoding-sample/repartition.py +++ b/scripts/encoding-sample/repartition.py @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + # Note: Plase modify the data source options for your case. import sys diff --git a/scripts/encoding-sample/run.sh b/scripts/encoding-sample/run.sh index 6a3a97b67..18127692e 100644 --- a/scripts/encoding-sample/run.sh +++ b/scripts/encoding-sample/run.sh @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + # clear rm -f encoding.zip main.py rm -f raw-*.csv diff --git a/scripts/encoding-sample/truncate-model.py b/scripts/encoding-sample/truncate-model.py index e946e9df3..0cde5026d 100644 --- a/scripts/encoding-sample/truncate-model.py +++ b/scripts/encoding-sample/truncate-model.py @@ -1,3 +1,17 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + import sys from pyspark.sql import SparkSession diff --git a/scripts/encoding/python/com/__init__.py b/scripts/encoding/python/com/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/__init__.py +++ b/scripts/encoding/python/com/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/encoding/python/com/nvidia/__init__.py b/scripts/encoding/python/com/nvidia/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/nvidia/__init__.py +++ b/scripts/encoding/python/com/nvidia/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/encoding/python/com/nvidia/spark/__init__.py b/scripts/encoding/python/com/nvidia/spark/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/nvidia/spark/__init__.py +++ b/scripts/encoding/python/com/nvidia/spark/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/encoding/python/com/nvidia/spark/encoding/__init__.py b/scripts/encoding/python/com/nvidia/spark/encoding/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/nvidia/spark/encoding/__init__.py +++ b/scripts/encoding/python/com/nvidia/spark/encoding/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/encoding/python/com/nvidia/spark/encoding/criteo/__init__.py b/scripts/encoding/python/com/nvidia/spark/encoding/criteo/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/nvidia/spark/encoding/criteo/__init__.py +++ b/scripts/encoding/python/com/nvidia/spark/encoding/criteo/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/scripts/encoding/python/com/nvidia/spark/encoding/utility/__init__.py b/scripts/encoding/python/com/nvidia/spark/encoding/utility/__init__.py index e69de29bb..0f6ef8237 100644 --- a/scripts/encoding/python/com/nvidia/spark/encoding/utility/__init__.py +++ b/scripts/encoding/python/com/nvidia/spark/encoding/utility/__init__.py @@ -0,0 +1,14 @@ +# Copyright (c) 2024, NVIDIA CORPORATION. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +