// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/factory/MultiLayerConfigurationFactory.java
// public interface MultiLayerConfigurationFactory {
// 
//     MultiLayerConfiguration create();
// 
// }
// 
// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/resource/ImageTransformConfigurationResource.java
// @Data
// public class ImageTransformConfigurationResource {
// 
//     @Inject
//     @Named("application.imageTransform.scaledHeight")
//     private Integer scaledHeight;
//     @Inject
//     @Named("application.imageTransform.scaledWidth")
//     private Integer scaledWidth;
//     @Inject
//     @Named("application.imageTransform.channels")
//     private Integer channels;
// 
// }
// 
// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/resource/NetworkConfigurationResource.java
// @Data
// public class NetworkConfigurationResource {
// 
//     @Inject
//     @Named("application.network.outputs")
//     private Integer outputs;
//     @Inject
//     @Named("application.network.epoch")
//     private Integer epoch;
//     @Inject
//     @Named("application.network.batchSize")
//     private Integer batchSize;
// 
// }


import lombok.Setter;
import net.scaliby.ceidgcaptcha.machinelearning.factory.MultiLayerConfigurationFactory;
import net.scaliby.ceidgcaptcha.machinelearning.resource.ImageTransformConfigurationResource;
import net.scaliby.ceidgcaptcha.machinelearning.resource.NetworkConfigurationResource;
import org.deeplearning4j.nn.api.OptimizationAlgorithm;
import org.deeplearning4j.nn.conf.MultiLayerConfiguration;
import org.deeplearning4j.nn.conf.NeuralNetConfiguration;
import org.deeplearning4j.nn.conf.Updater;
import org.deeplearning4j.nn.conf.inputs.InputType;
import org.deeplearning4j.nn.conf.layers.DenseLayer;
import org.deeplearning4j.nn.conf.layers.OutputLayer;
import org.deeplearning4j.nn.weights.WeightInit;
import org.nd4j.linalg.activations.Activation;
import org.nd4j.linalg.lossfunctions.LossFunctions;
import javax.inject.Inject;
import javax.inject.Named;
package net.scaliby.ceidgcaptcha.machinelearning.factory.impl;



public class MultiLayerConfigurationFactoryImpl implements MultiLayerConfigurationFactory {

    private static final int SEED = 1337;

    @Setter
    @Inject
    @Named("application.seed")
    private int seed = SEED;
    private final ImageTransformConfigurationResource imageTransformConfigurationResource;
    private final NetworkConfigurationResource networkConfigurationResource;

    @Inject
    public MultiLayerConfigurationFactoryImpl(ImageTransformConfigurationResource imageTransformConfigurationResource,
                                              NetworkConfigurationResource networkConfigurationResource) {
        this.networkConfigurationResource = networkConfigurationResource;
        this.imageTransformConfigurationResource = imageTransformConfigurationResource;
    }

    @Override
    public MultiLayerConfiguration create() {
        int width = imageTransformConfigurationResource.getScaledWidth();
        int height = imageTransformConfigurationResource.getScaledHeight();
// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/factory/MultiLayerConfigurationFactory.java
// public interface MultiLayerConfigurationFactory {
// 
//     MultiLayerConfiguration create();
// 
// }
// 
// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/resource/ImageTransformConfigurationResource.java
// @Data
// public class ImageTransformConfigurationResource {
// 
//     @Inject
//     @Named("application.imageTransform.scaledHeight")
//     private Integer scaledHeight;
//     @Inject
//     @Named("application.imageTransform.scaledWidth")
//     private Integer scaledWidth;
//     @Inject
//     @Named("application.imageTransform.channels")
//     private Integer channels;
// 
// }
// 
// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/resource/NetworkConfigurationResource.java
// @Data
// public class NetworkConfigurationResource {
// 
//     @Inject
//     @Named("application.network.outputs")
//     private Integer outputs;
//     @Inject
//     @Named("application.network.epoch")
//     private Integer epoch;
//     @Inject
//     @Named("application.network.batchSize")
//     private Integer batchSize;
// 
// }


// Path: ceidg-captcha-machine-learning/src/main/java/net/scaliby/ceidgcaptcha/machinelearning/factory/impl/MultiLayerConfigurationFactoryImpl.java
import lombok.Setter;
import net.scaliby.ceidgcaptcha.machinelearning.factory.MultiLayerConfigurationFactory;
import net.scaliby.ceidgcaptcha.machinelearning.resource.ImageTransformConfigurationResource;
import net.scaliby.ceidgcaptcha.machinelearning.resource.NetworkConfigurationResource;
import org.deeplearning4j.nn.api.OptimizationAlgorithm;
import org.deeplearning4j.nn.conf.MultiLayerConfiguration;
import org.deeplearning4j.nn.conf.NeuralNetConfiguration;
import org.deeplearning4j.nn.conf.Updater;
import org.deeplearning4j.nn.conf.inputs.InputType;
import org.deeplearning4j.nn.conf.layers.DenseLayer;
import org.deeplearning4j.nn.conf.layers.OutputLayer;
import org.deeplearning4j.nn.weights.WeightInit;
import org.nd4j.linalg.activations.Activation;
import org.nd4j.linalg.lossfunctions.LossFunctions;
import javax.inject.Inject;
import javax.inject.Named;

package net.scaliby.ceidgcaptcha.machinelearning.factory.impl;



public class MultiLayerConfigurationFactoryImpl implements MultiLayerConfigurationFactory {

    private static final int SEED = 1337;

    @Setter
    @Inject
    @Named("application.seed")
    private int seed = SEED;
    private final ImageTransformConfigurationResource imageTransformConfigurationResource;
    private final NetworkConfigurationResource networkConfigurationResource;

    @Inject
    public MultiLayerConfigurationFactoryImpl(ImageTransformConfigurationResource imageTransformConfigurationResource,
                                              NetworkConfigurationResource networkConfigurationResource) {
        this.networkConfigurationResource = networkConfigurationResource;
        this.imageTransformConfigurationResource = imageTransformConfigurationResource;
    }

    @Override
    public MultiLayerConfiguration create() {
        int width = imageTransformConfigurationResource.getScaledWidth();
        int height = imageTransformConfigurationResource.getScaledHeight();
        int channels = imageTransformConfigurationResource.getChannels();