{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/tera-self-supervised-learning-of-transformer","title":"TERA: Self-Supervised Learning of Transformer Encoder Representation for Speech","arxiv_id":"2007.06028","date":"2020-07-12","proceeding":null,"authors":["Andy T. Liu","Shang-Wen Li","Hung-Yi Lee"],"abstract":"We introduce a self-supervised speech pre-training method called TERA, which stands for Transformer Encoder Representations from Alteration. Recent approaches often learn by using a single auxiliary task like contrastive prediction, autoregressive prediction, or masked reconstruction. Unlike previous methods, we use alteration along three orthogonal axes to pre-train Transformer Encoders on a large amount of unlabeled speech. The model learns through the reconstruction of acoustic frames from their altered counterpart, where we use a stochastic policy to alter along various dimensions: time, frequency, and magnitude. TERA can be used for speech representations extraction or fine-tuning with downstream models. We evaluate TERA on several downstream tasks, including phoneme classification, keyword spotting, speaker recognition, and speech recognition. We present a large-scale comparison of various self-supervised models. TERA achieves strong performance in the comparison by improving upon surface features and outperforming previous models. In our experiments, we study the effect of applying different alteration techniques, pre-training on more data, and pre-training on various features. We analyze different model sizes and find that smaller models are strong representation learners than larger models, while larger models are more effective for downstream fine-tuning than smaller models. Furthermore, we show the proposed method is transferable to downstream datasets not used in pre-training.","url_abs":"https://arxiv.org/abs/2007.06028v3","url_pdf":"https://arxiv.org/pdf/2007.06028v3.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/andi611/Self-Supervised-Speech-Pretraining-and-Representation-Learning","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/s3prl/s3prl","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/592595/TERA","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/Pandade1997/tera_asvproof","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/Vernacular-ai/Multimodal-Slu","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/idiap/apam","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"NOASSERTION"}},{"paper_slug":"tera-self-supervised-learning-of-transformer","repo_url":"https://github.com/joselyn-rodriguez/s3prl","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"keyword-spotting","task_name":"Keyword Spotting"},{"task_slug":"self-supervised-learning","task_name":"Self-Supervised Learning"},{"task_slug":"speaker-recognition","task_name":"Speaker Recognition"},{"task_slug":"speech-recognition","task_name":"Speech Recognition"},{"task_slug":"transfer-learning","task_name":"Transfer Learning"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2007.06028","atlas_url":"https://app.syntology.ai/?focus=2007.06028","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2007.06028"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/592595/TERA","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/s3prl/s3prl","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Vernacular-ai/Multimodal-Slu","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/joselyn-rodriguez/s3prl","reach":{"status":"ok","spdx":"Apache-2.0"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/idiap/apam","reach":{"status":"ok","spdx":"NOASSERTION"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Pandade1997/tera_asvproof","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/andi611/Self-Supervised-Speech-Pretraining-and-Representation-Learning","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran_draft_wrong":3,"ran":5,"ran_honours":1,"ran_fixture":1,"unverified":4},"by_repo_kind":{"listed":{"samples":14,"ran":10,"repositories":2}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"0f786c407fb1ee4c","entry":"swish","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":2,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"0f786c407fb1ee4c"}},{"code_sha256_prefix":"017e86bd00a963bc","entry":"compare","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"utility/get_best_score.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/utility/get_best_score.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"017e86bd00a963bc"}},{"code_sha256_prefix":"fdc64f4c72036ae4","entry":"gelu","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"fdc64f4c72036ae4"}},{"code_sha256_prefix":"a9a4422e7a95a010","entry":"get_cosine_with_hard_restarts_schedule_with_warmup","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"schedulers.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/schedulers.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"a9a4422e7a95a010"}},{"code_sha256_prefix":"cecd81dc06f43149","entry":"get_grouped_parameters","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"optimizers.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/optimizers.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"cecd81dc06f43149"}},{"code_sha256_prefix":"24b061a6d0af9f9e","entry":"gumbel_softmax","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model_quantize.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model_quantize.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"24b061a6d0af9f9e"}},{"code_sha256_prefix":"4650349b06b3d90f","entry":"gumbel_softmax_sample","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model_quantize.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model_quantize.py","link_basis":"harvester_set","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4650349b06b3d90f"}},{"code_sha256_prefix":"8b8e06d04c4faf7f","entry":"load_model","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model_dual.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model_dual.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8b8e06d04c4faf7f"}},{"code_sha256_prefix":"d30d6c3098df2c42","entry":"prune_linear_layer","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d30d6c3098df2c42"}},{"code_sha256_prefix":"cec667e77fe8894d","entry":"sample_gumbel","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"transformer/model_quantize.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/transformer/model_quantize.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"cec667e77fe8894d"}},{"code_sha256_prefix":"28936c41e64792bd","entry":"get_cosine_schedule_with_warmup","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"schedulers.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/schedulers.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"28936c41e64792bd"}},{"code_sha256_prefix":"15a4c381f6af50fb","entry":"get_optimizer","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"optimizers.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/optimizers.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"15a4c381f6af50fb"}},{"code_sha256_prefix":"880bf296f53cdebf","entry":"get_scheduler","repo":"Vernacular-ai/Multimodal-Slu","repo_kind":"listed","path":"schedulers.py","file_url":"https://github.com/Vernacular-ai/Multimodal-Slu/blob/HEAD/schedulers.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"880bf296f53cdebf"}},{"code_sha256_prefix":"78826dfaa4289758","entry":"test_transformer","repo":"Pandade1997/tera_asvproof","repo_kind":"listed","path":"run_upstream.py","file_url":"https://github.com/Pandade1997/tera_asvproof/blob/HEAD/run_upstream.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"78826dfaa4289758"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}