Package nzilbb.encoding
Class IPA2DISC
- java.lang.Object
-
- nzilbb.encoding.PhonemeTranslator
-
- nzilbb.encoding.IPA2DISC
-
- All Implemented Interfaces:
Function<String,String>
,UnaryOperator<String>
public class IPA2DISC extends PhonemeTranslator
Translates IPA-encoded phonemic transcriptions using Unicode characters like tɹænskɹɪpʃən to CELEX-DISC-encoded transcriptions like tr{nskrIpS@nThis should support straight round-trip conversion with IPA symbols used by
DISC2IPA
, but also recognise other IPA symbols like /ʤ/, and Montreal Forced Aligner symbols like /ej/, for conversion to DISC.Mapping
1-to-1 mappings IPA DISC Example a ↔ & hat (German) Nasals æ̃ ↔ c timbre ɑ̃ː ↔ q détente æ̃ː ↔ 0 lingerie ɒ̃ː ↔ ~ bouillon Possible linking r ɹ ↔ R father Syllabics ŋ̩ ↔ C bacon m̩ ↔ F idealism n̩ ↔ H burden l̩ ↔ P dangle ɹ ↔ r rat ɡ ↔ g game (this is LATIN SMALL LETTER SCRIPT G which is always straight-backed) Monophthongs ɜː ↔ 3 NURSE æ ↔ { TRAP ʉ ↔ } put (Dutch) ɔː ↔ $ THOUGHT ɪ ↔ I KIT ʏ ↔ Y Pfütze ʌ ↔ V STRUT ɒ ↔ Q LOT ɔ ↔ O Glocke (German) ʊ ↔ U FOOT ə ↔ @ another Schwa uː ↔ u GOOSE iː ↔ i FLEECE ɛ ↔ E DRESS ɑː ↔ # BATH ɑ ↔ A kalevala (German) yː ↔ y für (German) oː ↔ o boot (German) ɛː ↔ ) Käse (German) øː ↔ | Möbel (German) œ̃ː ↔ ^ Parfum (German) œ ↔ / Götter (German) Diphthongs eɪ ↔ 1 FACE aɪ ↔ 2 PRICE ɔɪ ↔ 4 CHOICE əʊ ↔ 5 GOAT aʊ ↔ 6 MOUTH ɪə ↔ 7 NEAR ɛə ↔ 8 SQUARE ʊə ↔ 9 CURE ai ↔ W weit (German) au ↔ B Haut (German) ɔy ↔ X freut (German) œy ↔ L huis (Dutch) Consonants ŋ ↔ N bang θ ↔ T thin ð ↔ D then ʃ ↔ S sheep ʒ ↔ Z measure pf ↔ + Pferd (German) Affricates d͜ʒ ↔ _ jeep t͜ʃ ↔ J cheap t͜s ↔ = Zahl (German) Extensions to DISC, not in CELEX ʔ ↔ ? uh-oh Glottal Stop Any other symbol is passed through unchanged, including: p ↔ p pat b ↔ b bad t ↔ t tack d ↔ d dad k ↔ k cad g ↔ g game l ↔ l lad m ↔ m mad n ↔ n nat f ↔ f fat v ↔ v vat s ↔ s sap z ↔ z zap j ↔ j yank h ↔ h had w ↔ w why x ↔ x loch Other mappings IPA DISC Example Affricates ʤ → _ jeep (ligature) ʧ → J cheap (ligature) d͡ʒ → _ jeep (over-joined) t͡ʃ → J cheap (over-joined) Unicode's LATIN SMALL LETTER TURNED E instead of schwa ǝ → @ another ǝʊ → 5 MOUTH ɪǝ → 7 NEAR ɛǝ → 8 SQUARE ʊǝ → 9 CURE MFA phoneme labels aj → 2 PRICE aw → 6 MOUTH bʲ → bj attribute dʲ → dj duel dʒ → _ jeep ej → 1 FACE fʲ → fj fuel kʰ → k kangaroo mʲ → mj Munich pʰ → p Pacific pʲ → pj puberty tʰ → t table tʲ → tj tuition tʃ → J cheap vʲ → vj view ɐ → V understand ɒː → Q author ɔj → 4 CHOICE əw → 5 GOAT ɜ → 3 leisurely ɟ → g legume ɟʷ → g linguistics ɡ → g get ɫ → l milk ɫ̩ → P model ʉː → } ooze ʎ → j leak - Author:
- Robert Fromont robert@fromont.net.nz
- See Also:
DISC2IPA
-
-
Constructor Summary
Constructors Constructor Description IPA2DISC()
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
apply(String source)
Translates a phonemic transcription from the source encoding to the destination encoding.String
getDelimiter()
Getter fordelimiter
: Delimiter between IPA phonemes, if any.IPA2DISC
setDelimiter(String newDelimiter)
Setter fordelimiter
: Delimiter between IPA phonemes, if any.-
Methods inherited from class nzilbb.encoding.PhonemeTranslator
getDestinationEncoding, getSourceEncoding
-
-
-
-
Method Detail
-
getDelimiter
public String getDelimiter()
Getter fordelimiter
: Delimiter between IPA phonemes, if any.- Returns:
- Delimiter between IPA phonemes, if any.
-
setDelimiter
public IPA2DISC setDelimiter(String newDelimiter)
Setter fordelimiter
: Delimiter between IPA phonemes, if any.- Parameters:
newDelimiter
- Delimiter between IPA phonemes, if any.
-
-