当前位置: 首页>>代码示例>>C++>>正文


C++ LayerDimensions::deriveOthers方法代码示例

本文整理汇总了C++中LayerDimensions::deriveOthers方法的典型用法代码示例。如果您正苦于以下问题:C++ LayerDimensions::deriveOthers方法的具体用法?C++ LayerDimensions::deriveOthers怎么用?C++ LayerDimensions::deriveOthers使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LayerDimensions的用法示例。


在下文中一共展示了LayerDimensions::deriveOthers方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: compareSpecific

TEST( SLOW_testpropagate, compare_args ) {
    LayerDimensions dim;
    int batchSize = 128;
//    int imageSize = 19;
//    int filterSize = 7;
//    int inputPlanes = 64;
//    int numFilters = 64;
    int instance0 = 1;
    int instance1 = 3;
    int N = 128;
    bool debug = false;
    string activationName = "tanh";
    dim.setInputPlanes( 64 ).setInputImageSize(19).setNumFilters( 64 )
        .setFilterSize( 7 )
        .setPadZeros( true ).setBiased( false );    

    TestArgsParser::arg( "n", &N );
    DimFromArgs::arg( &dim );
    TestArgsParser::arg( "instance0", &instance0 );
    TestArgsParser::arg( "instance1", &instance1 );
    TestArgsParser::arg( "debug", &debug );
    TestArgsParser::arg( "batchsize", &batchSize );
    TestArgsParser::arg( "activation", &activationName );
    TestArgsParser::go();
    dim.deriveOthers();

    ActivationFunction *fn = ActivationFunction::fromName( activationName );
    compareSpecific( debug, N, batchSize, dim, fn, instance0, instance1 );
}
开发者ID:ChenFengAndy,项目名称:DeepCL,代码行数:29,代码来源:testpropagate.cpp

示例2: compareSpecific

TEST( testforward, comparespecific_break2 ) { // this breaks on v5.7.0 for example
    LayerDimensions dim;
    int batchSize = 4;
    int instance0 = 1;
    int instance1 = 5;
    int N = 4;
    bool debug = false;
    dim.setInputPlanes( 64 ).setInputSize(19).setNumFilters( 64 )
        .setFilterSize( 19 )
        .setPadZeros( false ).setBiased( false );    

    TestArgsParser::arg( "n", &N );
    DimFromArgs::arg( &dim );
    TestArgsParser::arg( "instance0", &instance0 );
    TestArgsParser::arg( "instance1", &instance1 );
    TestArgsParser::arg( "debug", &debug );
    TestArgsParser::arg( "batchsize", &batchSize );
    TestArgsParser::go();
    dim.deriveOthers();

    compareSpecific( debug, N, batchSize, dim, instance0, instance1 );    
}
开发者ID:2php,项目名称:DeepCL,代码行数:22,代码来源:testforward.cpp


注:本文中的LayerDimensions::deriveOthers方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。