五月天青色头像情侣网名,国产亚洲av片在线观看18女人,黑人巨茎大战俄罗斯美女,扒下她的小内裤打屁股

歡迎光臨散文網(wǎng) 會員登陸 & 注冊

FDF互助游戲開發(fā)原理丨FDF互助智能合約游戲系統(tǒng)開發(fā)(開發(fā)規(guī)則及詳情)

2023-03-07 16:10 作者:bili_16249894763  | 我要投稿

  From Web1.0 to Web3.0,from user read-only to user owned.Web1.0 is a read-only network,a static and one-way network,representing browsers and e-commerce;Web 2.0 pays more attention to user interaction.Users are both browsers and content producers.


The mode of development is from"read"to"write",and the representative products are social media and short video platforms;Web3.0 is the Internet of Value,and Web3.0 is a set of inclusive protocols that provide building blocks for application manufacturers


  void Calibration::_fake_quant_weights(){


  //找到權(quán)重中最大值(絕對值)的lamda函數(shù)


  auto findAbsMax=[&](const float*weights,const int size){


  float absMax=0;


  for(int i=0;i<size;i++){


  if(std::fabs(weights<i>)>absMax){


  absMax=std::fabs(weights<i>);


  }


  }


  return absMax;


  };


  for(const auto&op:_originaleModel->oplists){


  //跳過指定不需要量化的op,以及非Convolution


  std::vector<std::string>::iterator iter=std::find(_skip_quant_ops.begin(),_skip_quant_ops.end(),op->name);


  if(iter!=_skip_quant_ops.end()){需求及詳情I35模式7O98開發(fā)O7I8


  continue;


  }


  const auto opType=op->type;


  if(opType!=MNN::OpType_Convolution&&opType!=MNN::OpType_ConvolutionDepthwise){


  continue;


  }開發(fā)功能及源碼:MrsFu123


  auto param=op->main.AsConvolution2D();


  const int kernelNum=param->common->outputCount;


  std::vector<float>weights=param->weight;


  const int weightSize=weights.size();


  const int kernelSize=weightSize/kernelNum;


  //對每個kernel進(jìn)行量化


  for(int i=0;i<kernelNum;i++){


  const int offset=i*kernelSize;


  float absMax=findAbsMax(weights.data()+offset,kernelSize);


  float scale=absMax/_weightClampValue;//根據(jù)最大值計算縮放因子


  if(absMax<1e-6f){


  scale=absMax;


  }


  for(int j=0;j<kernelSize;j++){


  float value=weights[offset+j];


  float quantValue=std::round(value/scale);//量化到int8的值


  float clampedValue=std::max(std::min(quantValue,_weightClampValue),-_weightClampValue);//小于-127的部分,映射到-127


  float dequantValue=scale*clampedValue;


  param->weight[offset+j]=dequantValue;//反量化


  }


  }


  }


  }


FDF互助游戲開發(fā)原理丨FDF互助智能合約游戲系統(tǒng)開發(fā)(開發(fā)規(guī)則及詳情)的評論 (共 條)

分享到微博請遵守國家法律
齐河县| 株洲县| 玉山县| 江西省| 来凤县| 连平县| 密云县| 兰州市| 精河县| 霍林郭勒市| 涞水县| 罗源县| 河东区| 礼泉县| 土默特右旗| 迁安市| 兖州市| 新绛县| 彭山县| 攀枝花市| 岢岚县| 宿迁市| 青海省| 中阳县| 增城市| 丹巴县| 加查县| 潼关县| 南川市| 平潭县| 武平县| 浑源县| 通城县| 阳江市| 金山区| 乌兰察布市| 阿城市| 永川市| 石家庄市| 榆林市| 周宁县|