02-1tensorflow.nn主要功能模塊

Activation Functions
  • relu
  • relu6
  • elu
  • softplus
  • softsign
  • dropout
  • bias_add
  • sigmoid
  • tanh
Convolution
  • conv2d
  • depthwise_conv2d
  • separable_conv2d
  • atrous_conv2d
  • conv2d_transpose
  • conv3d
Pooling
  • avg_pool
  • max_pool
  • max_pool_with_argmax
  • avg_pool3d
  • max_pool3d
Morphological filtering

Morphological operators are non-linear filters used in image processing.

  • dilation2d
  • erosion2d
Normalization
  • l2_normalize
  • local_response_normalization
  • sufficient_statistics
  • normalize_moments
  • moments
Losses
  • l2_loss
  • log_poisson_loss
Classification

TensorFlow provides several operations that help you perform classification.

  • sigmoid_cross_entropy_with_logits
  • softmax
  • log_softmax
  • softmax_cross_entropy_with_logits
  • sparse_softmax_cross_entropy_with_logits
  • weighted_cross_entropy_with_logits
Embeddings

TensorFlow provides library support for looking up values in embedding tensors.

  • embedding_lookup
  • embedding_lookup_sparse
Recurrent Neural Networks

TensorFlow provides a number of methods for constructing Recurrent Neural Networks. Most accept an RNNCell-subclassed object (see the documentation for tf.nn.rnn_cell).

  • dynamic_rnn
  • rnn
  • state_saving_rnn
  • bidirectional_rnn
Conectionist Temporal Classification (CTC)
  • ctc_loss
  • ctc_greedy_decoder
  • ctc_beam_search_decoder
Evaluation

The evaluation ops are useful for measuring the performance of a network. Since they are nondifferentiable, they are typically used at evaluation time.

  • top_k
  • in_top_k
Candidate Sampling

Do you want to train a multiclass or multilabel model with thousands or millions of output classes (for example, a language model with a large vocabulary)? Training with a full Softmax is slow in this case, since all of the classes are evaluated for every training example. Candidate Sampling training algorithms can speed up your step times by only considering a small randomly-chosen subset of contrastive classes (called candidates) for each batch of training examples.

Sampled Loss Functions

TensorFlow provides the following sampled loss functions for faster training.

  • nce_loss
  • sampled_softmax_loss
Candidate Samplers

TensorFlow provides the following samplers for randomly sampling candidate classes when using one of the sampled loss functions above.

  • uniform_candidate_sampler
  • log_uniform_candidate_sampler
  • learned_unigram_candidate_sampler
  • fixed_unigram_candidate_sampler
Miscellaneous candidate sampling utilities
  • Miscellaneous candidate sampling utilities
Other Functions and Classes
  • batch_normalization
  • depthwise_conv2d_native
最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
  • 序言:七十年代末朽肥,一起剝皮案震驚了整個濱河市钦幔,隨后出現(xiàn)的幾起案子,更是在濱河造成了極大的恐慌丢郊,老刑警劉巖,帶你破解...
    沈念sama閱讀 217,277評論 6 503
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件,死亡現(xiàn)場離奇詭異,居然都是意外死亡步清,警方通過查閱死者的電腦和手機,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 92,689評論 3 393
  • 文/潘曉璐 我一進店門感局,熙熙樓的掌柜王于貴愁眉苦臉地迎上來尼啡,“玉大人暂衡,你說我怎么就攤上這事询微。” “怎么了狂巢?”我有些...
    開封第一講書人閱讀 163,624評論 0 353
  • 文/不壞的土叔 我叫張陵撑毛,是天一觀的道長。 經(jīng)常有香客問我唧领,道長藻雌,這世上最難降的妖魔是什么? 我笑而不...
    開封第一講書人閱讀 58,356評論 1 293
  • 正文 為了忘掉前任斩个,我火速辦了婚禮胯杭,結(jié)果婚禮上,老公的妹妹穿的比我還像新娘受啥。我一直安慰自己做个,他們只是感情好,可當(dāng)我...
    茶點故事閱讀 67,402評論 6 392
  • 文/花漫 我一把揭開白布滚局。 她就那樣靜靜地躺著居暖,像睡著了一般。 火紅的嫁衣襯著肌膚如雪藤肢。 梳的紋絲不亂的頭發(fā)上太闺,一...
    開封第一講書人閱讀 51,292評論 1 301
  • 那天,我揣著相機與錄音嘁圈,去河邊找鬼省骂。 笑死,一個胖子當(dāng)著我的面吹牛最住,可吹牛的內(nèi)容都是我干的钞澳。 我是一名探鬼主播,決...
    沈念sama閱讀 40,135評論 3 418
  • 文/蒼蘭香墨 我猛地睜開眼温学,長吁一口氣:“原來是場噩夢啊……” “哼略贮!你這毒婦竟也來了?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 38,992評論 0 275
  • 序言:老撾萬榮一對情侶失蹤逃延,失蹤者是張志新(化名)和其女友劉穎览妖,沒想到半個月后,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體揽祥,經(jīng)...
    沈念sama閱讀 45,429評論 1 314
  • 正文 獨居荒郊野嶺守林人離奇死亡讽膏,尸身上長有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點故事閱讀 37,636評論 3 334
  • 正文 我和宋清朗相戀三年,在試婚紗的時候發(fā)現(xiàn)自己被綠了拄丰。 大學(xué)時的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片府树。...
    茶點故事閱讀 39,785評論 1 348
  • 序言:一個原本活蹦亂跳的男人離奇死亡,死狀恐怖料按,靈堂內(nèi)的尸體忽然破棺而出奄侠,到底是詐尸還是另有隱情,我是刑警寧澤载矿,帶...
    沈念sama閱讀 35,492評論 5 345
  • 正文 年R本政府宣布垄潮,位于F島的核電站,受9級特大地震影響闷盔,放射性物質(zhì)發(fā)生泄漏弯洗。R本人自食惡果不足惜,卻給世界環(huán)境...
    茶點故事閱讀 41,092評論 3 328
  • 文/蒙蒙 一逢勾、第九天 我趴在偏房一處隱蔽的房頂上張望牡整。 院中可真熱鬧,春花似錦溺拱、人聲如沸逃贝。這莊子的主人今日做“春日...
    開封第一講書人閱讀 31,723評論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽秋泳。三九已至,卻和暖如春攒菠,著一層夾襖步出監(jiān)牢的瞬間迫皱,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 32,858評論 1 269
  • 我被黑心中介騙來泰國打工辖众, 沒想到剛下飛機就差點兒被人妖公主榨干…… 1. 我叫王不留卓起,地道東北人。 一個月前我還...
    沈念sama閱讀 47,891評論 2 370
  • 正文 我出身青樓凹炸,卻偏偏與公主長得像戏阅,于是被迫代替她去往敵國和親。 傳聞我的和親對象是個殘疾皇子啤它,可洞房花燭夜當(dāng)晚...
    茶點故事閱讀 44,713評論 2 354

推薦閱讀更多精彩內(nèi)容

  • 讓座 公交車行至一站臺奕筐,一老年人匆忙而上舱痘,緩慢的坐在座位上,突然一句不耐煩的聲音響起“忘了給錢了”离赫,轉(zhuǎn)而刺耳暴躁起...
    夜枝閱讀 207評論 0 1
  • 無意看到個新聞芭逝,就是說張智霖和袁詠儀這對恩愛的老夫妻花數(shù)百萬買車買包包享受生活,卻唯獨租房過了20年渊胸!這對隨時...
    妖媚兒閱讀 254評論 0 0
  • 闌夕聽雨閱讀 105評論 0 1
  • 政者萨咳,正也。子帥以正迂卢,孰敢不正? 《論語》 句意:政就是正的意思某弦。如果你能帶頭走正道,誰還敢不行正道呢?
    xcy無名閱讀 2,967評論 0 0