如何使用Scale来平均减少咖啡因

时间:2019-04-11 16:00:20

标签: python deep-learning conv-neural-network scale caffe

我想在namespace Trinity.Models { using System; using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.DataAnnotations; public partial class tblUser { public int Id { get; set; } [DisplayName("First Name")] [Required(ErrorMessage = "This field is required")] [RegularExpression(@"^[^\W\d_]+$", ErrorMessage = "Only letters allowed in your name")] public string FirstName { get; set; } [DisplayName("Last Name")] [Required(ErrorMessage = "This field is required")] [RegularExpression(@"^[^\W\d_]+$", ErrorMessage = "Only letters allowed in your name")] public string LastName { get; set; } public string BIO { get; set; } [DisplayName("E-Mail")] [Required(ErrorMessage = "This field is required")] [RegularExpression(@"\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*", ErrorMessage = "Incorrect E-mail Format")] public string Email { get; set; } [DataType(DataType.Password)] [Required(ErrorMessage = "This field is required")] [RegularExpression(@"^.*(?=.{8,})(?=.*[\d])(?=.*[\W]).*$", ErrorMessage = "Password must be 8 charhacters, contain atleast 1 digit and one special character")] public string Password { get; set; } [DisplayName("Confirm Password")] [DataType(DataType.Password)] [Required(ErrorMessage = "This field is required")] [Compare("Password", ErrorMessage ="Passwords are not the same")] public string ConfirmPassword { get; set; } public string Photo { get; set; } [DisplayName("Age")] [Required(ErrorMessage = "This field is required")] public int Age { get; set; } public string Sex { get; set; } public string Preferred { get; set; } } } 中实现平均值降低,而不是作为输入层的一部分。 我也希望它是一些常量值(彼此不同)的通道方式。我已经尝试过caffe图层,但没有找到单独减去每个通道的方法。

我很乐意提供帮助

编辑

我能够使用Scale层来解决这个问题,据我了解,该层用于实现bias层。

我正在分享我的解决方案:

首先创建原型:

Scale

之后,将数据注入到 layer params 中,如下所示:

layer {
    bottom: "bottom_layer"
    top: "top_layer"
    name: "mean_reduction"
    type: "Bias"
}

0 个答案:

没有答案