From c36055eb0ccad209fd2282110ea0a666562e9f89 Mon Sep 17 00:00:00 2001 From: jcowling Date: Thu, 19 Oct 2023 15:59:02 +0100 Subject: [PATCH 1/2] rename Dockerfiles --- ...kerfile.5.1.0.debian => Dockerfile.debian} | 0 ...1.0.debian.escu => Dockerfile.debian.escu} | 0 ...debian.rapids => Dockerfile.debian.rapids} | 0 ...rements => Dockerfile.debian.requirements} | 0 ...0.debian.spark => Dockerfile.debian.spark} | 0 ...formers => Dockerfile.debian.transformers} | 0 ...kerfile.5.1.0.redhat => Dockerfile.redhat} | 0 ...rements => Dockerfile.redhat.requirements} | 0 tag_mapping.csv | 24 +++++++++---------- 9 files changed, 12 insertions(+), 12 deletions(-) rename dockerfiles/{Dockerfile.5.1.0.debian => Dockerfile.debian} (100%) rename dockerfiles/{Dockerfile.5.1.0.debian.escu => Dockerfile.debian.escu} (100%) rename dockerfiles/{Dockerfile.5.1.0.debian.rapids => Dockerfile.debian.rapids} (100%) rename dockerfiles/{Dockerfile.5.1.0.debian.requirements => Dockerfile.debian.requirements} (100%) rename dockerfiles/{Dockerfile.5.1.0.debian.spark => Dockerfile.debian.spark} (100%) rename dockerfiles/{Dockerfile.5.1.0.debian.transformers => Dockerfile.debian.transformers} (100%) rename dockerfiles/{Dockerfile.5.1.0.redhat => Dockerfile.redhat} (100%) rename dockerfiles/{Dockerfile.5.1.0.redhat.requirements => Dockerfile.redhat.requirements} (100%) diff --git a/dockerfiles/Dockerfile.5.1.0.debian b/dockerfiles/Dockerfile.debian similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian rename to dockerfiles/Dockerfile.debian diff --git a/dockerfiles/Dockerfile.5.1.0.debian.escu b/dockerfiles/Dockerfile.debian.escu similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian.escu rename to dockerfiles/Dockerfile.debian.escu diff --git a/dockerfiles/Dockerfile.5.1.0.debian.rapids b/dockerfiles/Dockerfile.debian.rapids similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian.rapids rename to dockerfiles/Dockerfile.debian.rapids diff --git a/dockerfiles/Dockerfile.5.1.0.debian.requirements b/dockerfiles/Dockerfile.debian.requirements similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian.requirements rename to dockerfiles/Dockerfile.debian.requirements diff --git a/dockerfiles/Dockerfile.5.1.0.debian.spark b/dockerfiles/Dockerfile.debian.spark similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian.spark rename to dockerfiles/Dockerfile.debian.spark diff --git a/dockerfiles/Dockerfile.5.1.0.debian.transformers b/dockerfiles/Dockerfile.debian.transformers similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.debian.transformers rename to dockerfiles/Dockerfile.debian.transformers diff --git a/dockerfiles/Dockerfile.5.1.0.redhat b/dockerfiles/Dockerfile.redhat similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.redhat rename to dockerfiles/Dockerfile.redhat diff --git a/dockerfiles/Dockerfile.5.1.0.redhat.requirements b/dockerfiles/Dockerfile.redhat.requirements similarity index 100% rename from dockerfiles/Dockerfile.5.1.0.redhat.requirements rename to dockerfiles/Dockerfile.redhat.requirements diff --git a/tag_mapping.csv b/tag_mapping.csv index fcfc0b3..deb06be 100644 --- a/tag_mapping.csv +++ b/tag_mapping.csv @@ -1,13 +1,13 @@ Tags:,base_image,dockerfile,base_requirements,specific_requirements,runtime,requirements_dockerfile,stanza_name -minimal-cpu,python:3.9.13-bullseye,Dockerfile.5.1.0.debian,base_functional.txt,specific_minimal_cpu.txt,none,Dockerfile.5.1.0.debian.requirements,Minimal CPU (5.1.1) -minimal-gpu,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.5.1.0.debian,base_functional.txt,specific_minimal_gpu.txt,nvidia,Dockerfile.5.1.0.debian.requirements,Minimal GPU (5.1.1) -golden-cpu,python:3.9.13-bullseye,Dockerfile.5.1.0.debian,base_functional.txt,specific_golden_cpu.txt,none,Dockerfile.5.1.0.debian.requirements,Golden Image CPU (5.1.1) -golden-gpu,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.5.1.0.debian,base_functional.txt,specific_golden_gpu.txt,nvidia,Dockerfile.5.1.0.debian.requirements,Golden Image GPU (5.1.1) -ubi-functional-cpu,redhat/ubi9,Dockerfile.5.1.0.redhat,base_functional.txt,empty.txt,none,Dockerfile.5.1.0.redhat.requirements,Red Hat UBI Functional CPU (5.1.1) -ubi-minimal-cpu,redhat/ubi9,Dockerfile.5.1.0.redhat,base_functional.txt,specific_minimal_cpu.txt,none,Dockerfile.5.1.0.redhat.requirements,Red Hat UBI Minimal CPU (5.1.1) -ubi-golden-cpu,redhat/ubi9,Dockerfile.5.1.0.redhat,base_functional.txt,specific_golden_cpu_redhat.txt,none,Dockerfile.5.1.0.redhat.requirements,Red Hat UBI Golden CPU (5.1.1) -golden-gpu-transformers,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.5.1.0.debian.transformers,base_functional.txt,specific_golden_gpu_transformers.txt,nvidia,Dockerfile.5.1.0.debian.requirements,Transformers GPU (5.1.1) -golden-cpu-transformers,python:3.9.13-bullseye,Dockerfile.5.1.0.debian.transformers,base_functional.txt,specific_golden_cpu_transformers.txt,none,Dockerfile.5.1.0.debian.requirements,Transformers CPU (5.1.1) -golden-gpu-rapids,rapidsai/base:23.08-cuda11.2-py3.9,Dockerfile.5.1.0.debian.rapids,base_functional.txt,specific_rapids.txt,nvidia,Dockerfile.5.1.0.debian.requirements,Rapids 23.08 (5.1.1) -escu-cpu,python:3.9.13-bullseye,Dockerfile.5.1.0.debian.escu,base_functional.txt,specific_escu.txt,none,Dockerfile.5.1.0.debian.requirements,ESCU (5.1.1) -spark,jupyter/all-spark-notebook:spark-3.5.0,Dockerfile.5.1.0.debian.spark,base_functional.txt,specific_spark.txt,none,Dockerfile.5.1.0.debian.requirements,Spark 3.5.0 (5.1.1) \ No newline at end of file +minimal-cpu,python:3.9.13-bullseye,Dockerfile.debian,base_functional.txt,specific_minimal_cpu.txt,none,Dockerfile.debian.requirements,Minimal CPU (5.1.1) +minimal-gpu,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.debian,base_functional.txt,specific_minimal_gpu.txt,nvidia,Dockerfile.debian.requirements,Minimal GPU (5.1.1) +golden-cpu,python:3.9.13-bullseye,Dockerfile.debian,base_functional.txt,specific_golden_cpu.txt,none,Dockerfile.debian.requirements,Golden Image CPU (5.1.1) +golden-gpu,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.debian,base_functional.txt,specific_golden_gpu.txt,nvidia,Dockerfile.debian.requirements,Golden Image GPU (5.1.1) +ubi-functional-cpu,redhat/ubi9,Dockerfile.redhat,base_functional.txt,empty.txt,none,Dockerfile.redhat.requirements,Red Hat UBI Functional CPU (5.1.1) +ubi-minimal-cpu,redhat/ubi9,Dockerfile.redhat,base_functional.txt,specific_minimal_cpu.txt,none,Dockerfile.redhat.requirements,Red Hat UBI Minimal CPU (5.1.1) +ubi-golden-cpu,redhat/ubi9,Dockerfile.redhat,base_functional.txt,specific_golden_cpu_redhat.txt,none,Dockerfile.redhat.requirements,Red Hat UBI Golden CPU (5.1.1) +golden-gpu-transformers,nvidia/cuda:11.3.1-cudnn8-runtime-ubuntu20.04,Dockerfile.debian.transformers,base_functional.txt,specific_golden_gpu_transformers.txt,nvidia,Dockerfile.debian.requirements,Transformers GPU (5.1.1) +golden-cpu-transformers,python:3.9.13-bullseye,Dockerfile.debian.transformers,base_functional.txt,specific_golden_cpu_transformers.txt,none,Dockerfile.debian.requirements,Transformers CPU (5.1.1) +golden-gpu-rapids,rapidsai/base:23.08-cuda11.2-py3.9,Dockerfile.debian.rapids,base_functional.txt,specific_rapids.txt,nvidia,Dockerfile.debian.requirements,Rapids 23.08 (5.1.1) +escu-cpu,python:3.9.13-bullseye,Dockerfile.debian.escu,base_functional.txt,specific_escu.txt,none,Dockerfile.debian.requirements,ESCU (5.1.1) +spark,jupyter/all-spark-notebook:spark-3.5.0,Dockerfile.debian.spark,base_functional.txt,specific_spark.txt,none,Dockerfile.debian.requirements,Spark 3.5.0 (5.1.1) \ No newline at end of file From a0c5c819ae1adb8aabbf0e800f909ef402770568 Mon Sep 17 00:00:00 2001 From: huaibo-zhao-splunk Date: Fri, 8 Dec 2023 10:57:46 +0900 Subject: [PATCH 2/2] Fixed huggingface versioning error --- app/model/bert_phishing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/model/bert_phishing.py b/app/model/bert_phishing.py index 2439993..92e223b 100644 --- a/app/model/bert_phishing.py +++ b/app/model/bert_phishing.py @@ -114,7 +114,7 @@ def apply(model,df,param): # Load fine-tuned model file MODEL_DIRECTORY = "/srv/app/model/data/classification/en/bert_phishing" - model_par.load_state_dict(torch.load(os.path.join(MODEL_DIRECTORY, "pytorch_model.pt"), map_location=torch.device(device))) + model_par.load_state_dict(torch.load(os.path.join(MODEL_DIRECTORY, "pytorch_model.pt"), map_location=torch.device(device)),strict=False) state_dict = model_par.module.state_dict() model = BERT_Arch(bert)