DL4J中文文件/模型/模型動物園
可用模型
AlexNet
AlexNet
Dl4J的AlexNet模型解釋基於原始論文《基於深度卷積神經網路的ImageNet分類》和引用的imagenet示例程式碼。
參考文獻:
http://papers.nips.cc/paper/4824-imagenet-classification-with-deep-convolutional-neural-networks.pdfhttps://github.com/BVLC/caffe/blob/master/models/bvlc_alexnet/train_val.prototxt
在DL4J中建立基於可用功能的模型,註釋指示哪裡是等待增強的間隙。
論文中某些層中偏置是1,但是在imagenet示例程式碼中的是0.1,論文中所有層使用標準差為0.1的權重分佈, 但是在imagenet示例程式碼中的密連層使用0.005。
Darknet19
Darknet19
參考文獻: https://arxiv.org/pdf/1612.08242.pdf
該模型的ImageNet權重是可用的,並且已經從https://pjreddie.com/darknet/imagenet/使用https://github.com/allanzelener/YAD2K進行了轉換。
有2個預先訓練的模型,一個為224x224影象和一個微調448×448影象。初始化之前呼叫{ 3, 224, 224 }或{ 3, 448, 448 }的setInputShape()。輸入影象的通道需要以RGB順序(而不是BGR),值在[0, 1 ]內歸一化。輸出標籤為:
FaceNetNN4Small2
依賴於嵌入和三重損失的原始FaceNet模型的變體。參考文獻: https://arxiv.org/abs/1503.03832
還基於OpenFace實現:http://reports-archive.adm.cs.cmu.edu/anon/2016/CMU-CS-16-118.pdf
InceptionResNetV1
依賴於嵌入和三重損失的原始FaceNet模型的變體。參考文獻:
還基於OpenFace實現:http://reports-archive.adm.cs.cmu.edu/anon/2016/CMU-CS-16-118.pdf
LeNet
LeNet是ImageNet資料集上的早期有希望的成就者。參考文獻:
- http://yann.lecun.com/exdb/publis/pdf/lecun-98.pdf
- https://github.com/BVLC/caffe/blob/master/examples/mnist/lenet.prototxt
該模型的MNIST權重是可用的,並且已經從 https://github.com/f00-/mnist-lenet-keras 轉換。
NASNet
U-Net
NASNet-A在DL4J中的實現。NASNet引用了神經架構搜尋網路, 通過直接在感興趣的資料集中學習模型架構而自動設計的一系列模型。
此實現使用1056個倒數第二濾波器和輸入形狀(3, 224, 224)。你可以改變這個。
論文: https://arxiv.org/abs/1707.07012 這個模型的ImageNet權重是可用的,並且已經從https://keras.io/applications/轉換。
ResNet50
深度學習殘差網路
論文: https://arxiv.org/abs/1512.03385 這個模型的ImageNet權重是可用的,並且已經從https://keras.io/applications/轉換。
SimpleCNN
一種用於一般影象分類的簡單卷積網路。參考文獻: https://github.com/oarriaga/face_classification/
SqueezeNet
U-Net
SqueezeNet的實現。與AlexNet小部分引數精度相似。
論文: https://arxiv.org/abs/1602.07360 這個模型的ImageNet權重是可用的,並且已經從 https://github.com/rcmalli/keras-squeezenet/ 轉換
TextGenerationLSTM
設計用於文字生成的LSTM。可以在文字語料庫上進行訓練。對於這個模型,numClasses是
遵循這一實現:https://github.com/fchollet/keras/blob/master/examples/lstm_text_generation.py 的架構
沃爾特·惠特曼權重可用於從他的作品生成文字,改編自 https://github.com/craigomac/InfiniteMonkeys.
TinyYOLO
Tiny YOLO 參考文獻: https://arxiv.org/pdf/1612.08242.pdf
該模型的ImageNet+VOC權重是可用的,並且已經從https://pjreddie.com/darknet/yolo使用 https://github.com/allanzelener/YAD2K 和以下程式碼進行了轉換。
String filename = “tiny-yolo-voc.h5”; ComputationGraph graph = KerasModelImport.importKerasModelAndWeights(filename, false);
INDArray priors = Nd4j.create(priorBoxes);
FineTuneConfiguration fineTuneConf = new FineTuneConfiguration.Builder() .seed(seed) .iterations(iterations) .optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) .gradientNormalization(GradientNormalization.RenormalizeL2PerLayer) .gradientNormalizationThreshold(1.0)
.updater(new Adam.Builder().learningRate(1e-3).build())
.l2(0.00001)
.activation(Activation.IDENTITY)
.trainingWorkspaceMode(workspaceMode)
.inferenceWorkspaceMode(workspaceMode)
.build();
ComputationGraph model = new TransferLearning.GraphBuilder(graph) .fineTuneConfiguration(fineTuneConf)
.addLayer(“outputs”, new Yolo2OutputLayer.Builder() .boundingBoxPriors(priors) .build(), “conv2d_9”)
.setOutputs(“outputs”)
.build();
System.out.println(model.summary(InputType.convolutional(416, 416, 3)));
ModelSerializer.writeModel(model, “tiny-yolo-voc_dl4j_inference.v1.zip”, false);
416X416輸入影象的通道需要以RGB順序(而不是BGR),值在[0, 1 ]內歸一化。
UNet
U-Net
U-NET是一種深度學習網路,在DL4J中用於影象分割。U-NET-卷積網路結構用於影象的快速精確分割。到目前為止,它在分割神經元結構的電子棧ISBI的挑戰中已經優於現有的最佳方法(滑動視窗卷積網路)。
論文:https://arxiv.org/abs/1505.04597權重在合成數據集上訓練的影象分割中可用。
VGG16
VGG-16,來自非常深的卷積網路用於大規模影象識別。https://arxiv.org/abs/1409.1556
深度人臉識別
http://www.robots.ox.ac.uk/~vgg/publications/2015/Parkhi15/parkhi15.pdf
該模型的ImageNet權重是可用的,並且已經從https://github.com/fchollet/keras/tree/1.1.2/keras/applications進行了轉換。
該模型的CIFAR-10權重是可用的,並且已經使用來自https://github.com/rajatvikramsingh/cifar10-vgg16的“approach 2”進行了轉換。
這個模型的VGGFace權重是可用的,並且已經從https://github.com/rcmalli/keras-vggface轉換。
VGG19
VGG-19,來自非常深的卷積網路用於大規模影象識別。
https://arxiv.org/abs/1409.1556
該模型的ImageNet權重是可用的,並且已經從 https://github.com/fchollet/keras/tree/1.1.2/keras/applications 進行了轉換。
Xception
U-Net
An implementation of Xception in Deeplearning4j. A novel deep convolutional neural network architecture inspired by Inception, where Inception modules have been replaced with depthwise separable convolutions.
Xception在DL4J中的實現。受Inception的啟發,一種新的深度卷積神經網路結構,其中Inception模組已經被深度可分離卷積所取代。
論文: https://arxiv.org/abs/1610.02357 該模型的ImageNet權重是可用的,並且已經從 https://keras.io/applications/ 進行了轉換。
YOLO2
YOLOv2 參考文獻: https://arxiv.org/pdf/1612.08242.pdf
這個模型的ImageNet+COCO權重是可用的,並且已經從https://pjreddie.com/darknet/yolo使用https://github.com/allanzelener/YAD2K和如下程式碼進行了轉換。
String filename = “yolo.h5”;
KerasLayer.registerCustomLayer(“Lambda”, KerasSpaceToDepth.class);
ComputationGraph graph = KerasModelImport.importKerasModelAndWeights(filename, false); INDArray priors = Nd4j.create(priorBoxes);
FineTuneConfiguration fineTuneConf = new FineTuneConfiguration.Builder()
.seed(seed)
.optimizationAlgo(OptimizationAlgorithm.STOCHASTIC_GRADIENT_DESCENT) .gradientNormalization(GradientNormalization.RenormalizeL2PerLayer) .gradientNormalizationThreshold(1.0)
.updater(new Adam.Builder().learningRate(1e-3).build())
.l2(0.00001)
.activation(Activation.IDENTITY)
.trainingWorkspaceMode(workspaceMode)
.inferenceWorkspaceMode(workspaceMode)
.build();
ComputationGraph model = new TransferLearning.GraphBuilder(graph) .fineTuneConfiguration(fineTuneConf)
.addLayer(“outputs”, new Yolo2OutputLayer.Builder() .boundingBoxPriors(priors) .build(), “conv2d_23”)
.setOutputs(“outputs”)
.build();
System.out.println(model.summary(InputType.convolutional(608, 608, 3)));
ModelSerializer.writeModel(model, “yolo2_dl4j_inference.v1.zip”, false);
608X608輸入影象的通道需要以RGB順序(而不是BGR),值在[0, 1 ]內歸一化。
pretrainedUrl
public String pretrainedUrl(PretrainedType pretrainedType)
模型的預設先驗框