mirror of
https://gitee.com/mymagicpower/AIAS.git
synced 2024-11-29 18:58:16 +08:00
no message
This commit is contained in:
parent
838200ab8f
commit
b910488451
@ -28,7 +28,7 @@ public final class ImageEncoderModel {
|
||||
//.optModelUrls("/Users/calvin/CLIP-ViT-B-32-IMAGE/CLIP-ViT-B-32-IMAGE.zip")
|
||||
.optTranslator(new ImageTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -28,7 +28,7 @@ public final class StyleTransfer {
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optModelUrls(modelUrl)
|
||||
.optProgress(new ProgressBar())
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optTranslatorFactory(new StyleTransferTranslatorFactory())
|
||||
.build();
|
||||
|
||||
|
@ -27,7 +27,7 @@ public final class LightFaceDetection {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -27,7 +27,7 @@ public final class RetinaFaceDetection {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -19,7 +19,7 @@ public final class FaceFeature {
|
||||
.optTranslator(new FaceFeatureTranslator())
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -27,7 +27,7 @@ public final class LightFaceDetection {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -27,7 +27,7 @@ public final class RetinaFaceDetection {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -41,7 +41,7 @@ public final class FireSmokeDetect {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -42,7 +42,7 @@ public final class LargeHelmetHeadPersonDetect {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -42,7 +42,7 @@ public final class ReflectiveVest {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -42,7 +42,7 @@ public final class Yolov5lDetect {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -42,7 +42,7 @@ public final class Yolov5mDetect {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -42,7 +42,7 @@ public final class Yolov5sDetect {
|
||||
.optTranslator(translator)
|
||||
.optProgress(new ProgressBar())
|
||||
.optEngine("PyTorch")
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.build();
|
||||
|
||||
return criteria;
|
||||
|
@ -22,7 +22,7 @@ public final class SentenceEncoder {
|
||||
// .optModelUrls("/Users/calvin/models/paraphrase-xlm-r-multilingual-v1/")
|
||||
.optTranslator(new SentenceTransTranslator(processor))
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class SentenceEncoder {
|
||||
// .optModelUrls("/Users/calvin/models/distiluse-base-multilingual-cased-v1/")
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class SentenceEncoderEN {
|
||||
// .optModelUrls("/Users/calvin/msmarco-MiniLM-L-6-v3/")
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -23,7 +23,7 @@ public final class ImageEncoder {
|
||||
// .optModelUrls("/Users/calvin/CLIP-ViT-B-32-IMAGE/")
|
||||
.optTranslator(new ImageTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -18,7 +18,7 @@ public final class TextEncoder {
|
||||
// .optModelUrls("/Users/calvin/M-BERT-Base-ViT-B/")
|
||||
.optTranslator(new TextTranslator(isChinese))
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -24,7 +24,7 @@ public final class ImageEncoder {
|
||||
// .optModelUrls("/Users/calvin/CLIP-ViT-B-32-IMAGE/")
|
||||
.optTranslator(new ImageTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -23,7 +23,7 @@ public final class TextEncoder {
|
||||
// .optModelUrls("/Users/calvin/CLIP-ViT-B-32-TEXT/")
|
||||
.optTranslator(new TextTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -23,7 +23,7 @@ public final class ImageEncoder {
|
||||
// .optModelUrls("/Users/calvin/CLIP-ViT-B-32-IMAGE/")
|
||||
.optTranslator(new ImageTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class TextEncoder {
|
||||
// .optModelUrls("/Users/calvin/CLIP-ViT-B-32-TEXT/")
|
||||
.optTranslator(new TextTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -20,7 +20,7 @@ public final class TinyBertCrossEncoder {
|
||||
// .optModelUrls("/Users/calvin/ms-marco-TinyBERT-L-2-v2/")
|
||||
.optTranslator(new CrossEncoderTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class QANaturalQuestions {
|
||||
// .optModelUrls("/Users/calvin/nq-distilbert-base-v1/")
|
||||
.optTranslator(new QATranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class QuestionAnswerRetrieval {
|
||||
// .optModelUrls("/Users/calvin/msmarco-MiniLM-L-6-v3/")
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class SemanticSearchPublications {
|
||||
// .optModelUrls("/Users/calvin/allenai-specter/")
|
||||
.optTranslator(new SemanticSearchTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -24,7 +24,7 @@ public final class SentimentAnalysis {
|
||||
// "/Users/calvin/Documents/build/pytorch_models/distilbert_sst_english/")
|
||||
.optTranslator(new PtDistilBertTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -18,7 +18,7 @@ public class SpeakerEncoder {
|
||||
// .optModelPath(Paths.get("src/main/resources/voice/tacotronSTFT.pt"))
|
||||
.optTranslator(new SpeakerEncoderTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -18,7 +18,7 @@ public class SpeakerEncoder {
|
||||
// .optModelPath(Paths.get("src/main/resources/voice/tacotronSTFT.pt"))
|
||||
.optTranslator(new SpeakerEncoderTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -16,7 +16,7 @@ public class Tacotron2Encoder {
|
||||
.optModelUrls("https://aias-home.oss-cn-beijing.aliyuncs.com/models/speech_models/tacotron2.zip")
|
||||
.optTranslator(new TacotronTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -17,7 +17,7 @@ public class DenoiserEncoder {
|
||||
"https://aias-home.oss-cn-beijing.aliyuncs.com/models/speech_models/denoiser.zip")
|
||||
.optTranslator(new DenoiserTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -17,7 +17,7 @@ public class WaveGlowEncoder {
|
||||
"https://aias-home.oss-cn-beijing.aliyuncs.com/models/speech_models/waveGlow.zip")
|
||||
.optTranslator(new WaveGlowTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -18,7 +18,7 @@ public class SpeakerEncoder {
|
||||
// .optModelPath(Paths.get("src/main/resources/voice/tacotronSTFT.pt"))
|
||||
.optTranslator(new SpeakerEncoderTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -16,7 +16,7 @@ public class Tacotron2Encoder {
|
||||
.optModelUrls("https://aias-home.oss-cn-beijing.aliyuncs.com/models/speech_models/tacotron2.zip")
|
||||
.optTranslator(new TacotronTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -19,7 +19,7 @@ public class Tacotron {
|
||||
// .optModelPath(Paths.get("src/main/resources/voice/tacotronSTFT.pt"))
|
||||
.optTranslator(new TacotronTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class SentenceEncoder {
|
||||
// .optModelUrls("/Users/calvin/models/distiluse-base-multilingual-cased-v1/")
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -24,7 +24,7 @@ public final class SentimentAnalysis {
|
||||
// "/Users/calvin/Documents/build/pytorch_models/distilbert_sst_english/")
|
||||
.optTranslator(new PtDistilBertTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -22,7 +22,7 @@ public final class SentenceEncoder {
|
||||
// .optModelUrls("/Users/calvin/models/distiluse-base-multilingual-cased-v1/")
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -24,7 +24,7 @@ public final class SentimentAnalysis {
|
||||
// "/Users/calvin/Documents/build/pytorch_models/distilbert_sst_english/")
|
||||
.optTranslator(new PtDistilBertTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -52,7 +52,7 @@ public final class FaceDetectionModel {
|
||||
.optModelUrls(layoutUri)
|
||||
.optTranslator(translator)
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -45,7 +45,7 @@ public final class FaceFeatureModel {
|
||||
.optModelUrls(layoutUri)
|
||||
.optTranslator(new FaceFeatureTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -41,7 +41,7 @@ public final class ImageEncoderModel {
|
||||
.optTranslator(new ImageTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optDevice(Device.cpu())
|
||||
// .optOption("mapLocation", "true")
|
||||
// .optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -40,7 +40,7 @@ public final class TextEncoderModel {
|
||||
.optTranslator(new TextTranslator(isChinese))
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optDevice(Device.cpu())
|
||||
// .optOption("mapLocation", "true")
|
||||
// .optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
|
||||
|
@ -44,7 +44,7 @@ public final class SentenceEncoderModel {
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optDevice(Device.cpu())
|
||||
// .optOption("mapLocation", "true")
|
||||
// .optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -39,7 +39,7 @@ public final class FaceFeatureModel {
|
||||
.optTranslator(new FaceFeatureTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optDevice(Device.cpu())
|
||||
// .optOption("mapLocation", "true")
|
||||
// .optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -39,7 +39,7 @@ public final class VoiceprintModel {
|
||||
.optModelUrls(modelUri)
|
||||
.optTranslator(new VoiceprintTranslator())
|
||||
.optEngine("PaddlePaddle") // Use PyTorch engine
|
||||
//.optOption("mapLocation", "true")
|
||||
//.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -46,7 +46,7 @@ public final class FaceDetectionModel {
|
||||
.optModelUrls(layoutUri)
|
||||
.optTranslator(translator)
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -38,7 +38,7 @@ public final class FaceFeatureModel {
|
||||
.optModelUrls(layoutUri)
|
||||
.optTranslator(new FaceFeatureTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
@ -47,7 +47,7 @@ public final class SentenceEncoderModel {
|
||||
.optModelUrls(modelUri)
|
||||
.optTranslator(new SentenceTransTranslator())
|
||||
.optEngine("PyTorch") // Use PyTorch engine
|
||||
.optOption("mapLocation", "true")
|
||||
.optDevice(Device.cpu())
|
||||
.optProgress(new ProgressBar())
|
||||
.build();
|
||||
return criteria;
|
||||
|
Loading…
Reference in New Issue
Block a user