Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/aboSamoor/pycld2
/ functions
Functions
421 in github.com/aboSamoor/pycld2
⨍
Functions
421
◇
Types & classes
16
↓ 2 callers
Function
CarefulMatch
cld2/internal/scoreutf8text.cc:161
↓ 2 callers
Function
CopyOneQuotedString
Copy attribute value in [pos..max_pos) pos is just after an opening quote/apostrophe and max_pos is the ending one String must all be on a single line
cld2/internal/compact_lang_det_hint_code.cc:1355
↓ 2 callers
Function
CountCommas
cld2/internal/compact_lang_det_hint_code.cc:998
↓ 2 callers
Method
CurrentTopThreeKeys
Return current top three keys
cld2/internal/tote.cc:65
↓ 2 callers
Function
DefaultLanguage
cld2/internal/lang_script.cc:314
↓ 2 callers
Function
DumpSummaryBuffer
cld2/internal/scoreonescriptspan.cc:652
↓ 2 callers
Function
ExtDetectLanguageSummary
Scan interchange-valid UTF-8 bytes and detect list of top 3 extended languages. Extended languages are additional Google interface languages and Unico
cld2/internal/compact_lang_det.cc:181
↓ 2 callers
Function
ExtLanguageCode
Given the Language, return the language code, e.g. "ko"
cld2/internal/lang_script.cc:245
↓ 2 callers
Function
ExtractLangEtc
Extract return values before fixups
cld2/internal/compact_lang_det_impl.cc:1276
↓ 2 callers
Function
FixUnicodeValue
Guarantees that the resulting output value is interchange valid 00-FF; map to spaces or MS CP1252 D800-DFFF; surrogates FDD0-FDEF; non-characters xxFF
cld2/internal/fixunicodevalue.cc:29
↓ 2 callers
Function
FlagBestEffort
cld2/internal/compact_lang_det_impl.cc:440
↓ 2 callers
Function
FlagFinish
cld2/internal/compact_lang_det_impl.cc:433
↓ 2 callers
Function
FlagRepeats
cld2/internal/compact_lang_det_impl.cc:435
↓ 2 callers
Function
ForwardscanToSpace
Forwardscan to word boundary, returning how many bytes n to go forward so that src + n is non-space ans src + n - 1 is space. If not found in kMaxSpac
cld2/internal/compact_lang_det_impl.cc:509
↓ 2 callers
Function
GetColorHtmlEscapedText
cld2/internal/debug.cc:251
↓ 2 callers
Function
GetNextLangprob
Advances src, decrements len
cld2/internal/cldutil_offline.cc:48
↓ 2 callers
Function
GetULScriptFromName
cld2/internal/lang_script.cc:464
↓ 2 callers
Function
IsEFIGS
cld2/internal/compact_lang_det_impl.cc:1394
↓ 2 callers
Function
IsFIGS
cld2/internal/compact_lang_det_impl.cc:1386
↓ 2 callers
Function
ItemToVector
If next chunk language matches last vector language, extend last element Otherwise add new element to vector
cld2/internal/scoreonescriptspan.cc:323
↓ 2 callers
Function
Microseconds
Convert GetTimeOfDay output to 64-bit usec
cld2/internal/compact_lang_det_test.cc:66
↓ 2 callers
Method
MoveRight
Move active window one range to the right Return true if move was OK
cld2/internal/offsetmap.cc:355
↓ 2 callers
Function
OctaHash40Mix
OCTAGRAM Pick up 1..24 bytes plus pre/post space and hash them via mask/shift/add UNDERSHOOTS 1 byte, OVERSHOOTS up to 3 bytes The low 32 bits follow
cld2/internal/cldutil_shared.cc:234
↓ 2 callers
Function
PrintableIndirect
If high bit is on, take out high bit and add 2B to make table2 entries easy
cld2/internal/scoreonescriptspan.cc:555
↓ 2 callers
Function
ProcessHitBuffer
cld2/internal/scoreonescriptspan.cc:1067
↓ 2 callers
Function
ProcessProbV2Tote
BIGRAM, QUADGRAM, OCTAGRAM score one => tote Input: 4-byte entry of 3 language numbers and one probability subscript, plus an accumulator tote. (langu
cld2/internal/cldutil_offline.cc:35
↓ 2 callers
Function
ProcessProbV2Tote
BIGRAM, QUADGRAM, OCTAGRAM score one => tote Input: 4-byte entry of 3 language numbers and one probability subscript, plus an accumulator tote. (langu
cld2/internal/cldutil.cc:128
↓ 2 callers
Function
QuadHashV2
QUADGRAM wrapper with surrounding spaces Pick up 1..12 bytes plus pre/post space and hash them via mask/shift/add UNDERSHOOTS 1 byte, OVERSHOOTS up to
cld2/internal/cldutil_shared.cc:196
↓ 2 callers
Function
QuadHashV2Mix
QUADGRAM Pick up 1..12 bytes plus pre/post space and hash them via mask/shift/add OVERSHOOTS up to 3 bytes For runtime use of tables Does X86 unaligne
cld2/internal/cldutil_shared.cc:167
↓ 2 callers
Function
RunTests
cld2/internal/cld2_unittest.cc:288
↓ 2 callers
Function
ScanToLetterOrSpecial
Quick Skip to next letter or < > & or to end of string (eos) Always return is_letter for eos
cld2/internal/getonescriptspan.cc:480
↓ 2 callers
Function
SetCLDLangTagsHint
Add hints to vector of langpriors Input is from GetLangTagsFromHtml(), already lowercased
cld2/internal/compact_lang_det_hint_code.cc:1394
↓ 2 callers
Function
SetCLDPriorWeight
cld2/internal/compact_lang_det_hint_code.cc:925
↓ 2 callers
Method
Sort
Sort first n entries by decreasing order of value If key==0 other fields are not valid, treat value as -1
cld2/internal/tote.cc:221
↓ 2 callers
Function
SpanInterchangeValid
Returns the length in bytes of the prefix of src that is all interchange valid UTF-8
cld2/internal/compact_lang_det_impl.cc:74
↓ 2 callers
Function
SpliceHitBuffer
cld2/internal/scoreonescriptspan.cc:1118
↓ 2 callers
Function
ULScriptRecognitionType
cld2/internal/lang_script.cc:154
↓ 2 callers
Function
ascii_isdigit
cld2/internal/getonescriptspan.cc:303
↓ 2 callers
Function
ascii_isxdigit
cld2/internal/getonescriptspan.cc:306
↓ 2 callers
Function
calculateHeaderSize
cld2/internal/cld2_dynamic_data.cc:45
↓ 2 callers
Function
isDataDynamic
cld2/internal/compact_lang_det_impl.cc:106
↓ 2 callers
Function
loadDataFile
cld2/internal/cld2_dynamic_data_loader.cc:164
↓ 2 callers
Function
loadDataFromRawAddress
cld2/internal/compact_lang_det_impl.cc:123
↓ 2 callers
Function
loadDataInternal
cld2/internal/cld2_dynamic_data_loader.cc:195
↓ 2 callers
Function
loadHeaderFromFile
cld2/internal/cld2_dynamic_data_loader.cc:33
↓ 2 callers
Function
loadInternal
cld2/internal/cld2_dynamic_data_loader.cc:54
↓ 2 callers
Method
runOne
(self, expectedLangName, s, doFull = False)
bindings/test.py:271
↓ 2 callers
Function
setDebug
cld2/internal/cld2_dynamic_data.cc:22
↓ 2 callers
Function
unloadDataFile
cld2/internal/cld2_dynamic_data_loader.cc:141
↓ 2 callers
Function
unloadDataRaw
cld2/internal/cld2_dynamic_data_loader.cc:155
↓ 1 callers
Function
AddDistinctBoost2
Update scoring context distinct_boost for distinct octagram Keep last 4 used. Since these are mostly (except at splices) in hitbuffer, we might be abl
cld2/internal/scoreonescriptspan.cc:112
↓ 1 callers
Function
AddLangPriorBoost
cld2/internal/compact_lang_det_impl.cc:1524
↓ 1 callers
Method
AddScoreCount
Increment count of quadgrams/trigrams/unigrams scored
cld2/internal/tote.cc:47
↓ 1 callers
Function
ApplyHints
cld2/internal/compact_lang_det_impl.cc:1587
↓ 1 callers
Function
BetterBoundary
Within hitbufer->linear[] <-- prior chunk --><-- this chunk --> | | | linear0 linear1 linear2 la
cld2/internal/scoreonescriptspan.cc:671
↓ 1 callers
Function
BiLen
src points to a letter. Find the byte length of a bigram starting there.
cld2/internal/cldutil_shared.cc:403
↓ 1 callers
Function
CalcSummaryLang
Calculate a single summary language for the document, and its reliability. Returns language3[0] or language3[1] or ENGLISH or UNKNOWN_LANGUAGE This is
cld2/internal/compact_lang_det_impl.cc:1414
↓ 1 callers
Function
CheapRepWordsInplace
Remove words of text that have more than half their letters predicted correctly by our cheap predictor, moving the remaining words in-place to the fro
cld2/internal/compact_lang_det_impl.cc:610
↓ 1 callers
Function
CheapRepWordsInplaceOverwrite
This alternate form overwrites redundant words, thus avoiding corrupting the backmap for generating a vector of original-text ranges.
cld2/internal/compact_lang_det_impl.cc:697
↓ 1 callers
Function
CheapSqueezeInplace
Remove portions of text that have a high density of spaces, or that are overly repetitive, squeezing the remaining text in-place to the front of the i
cld2/internal/compact_lang_det_impl.cc:785
↓ 1 callers
Function
CheapSqueezeInplaceOverwrite
This alternate form overwrites redundant words, thus avoiding corrupting the backmap for generating a vector of original-text ranges.
cld2/internal/compact_lang_det_impl.cc:869
↓ 1 callers
Function
CheapSqueezeTriggerTest
Timing 2.8GHz P4 (dsites 2008.03.20) with 170KB input About 90 MB/sec, with or without memcpy, chunksize 48 or 4096 Just CountSpaces is about 340 MB/s
cld2/internal/compact_lang_det_impl.cc:952
↓ 1 callers
Function
ChunkAll
Break linear array into chunks of ~20 quadgram hits or ~50 CJK unigram hits
cld2/internal/scoreonescriptspan.cc:978
↓ 1 callers
Function
CopyQuotedString
Find and copy attribute value: quoted string in [pos..max_pos) Return slightly-normalized language list, empty or ending in comma
cld2/internal/compact_lang_det_hint_code.cc:1382
↓ 1 callers
Function
DefaultLangProb
Make a langprob that gives small weight to the default language for ulscript
cld2/internal/scoreonescriptspan.cc:848
↓ 1 callers
Function
DetectLanguage
Scan interchange-valid UTF-8 bytes and detect most likely language
cld2/internal/compact_lang_det.cc:59
↓ 1 callers
Function
DetectLanguageSummary
Scan interchange-valid UTF-8 bytes and detect list of top 3 languages.
cld2/internal/compact_lang_det.cc:98
↓ 1 callers
Function
DoSpecialFixup
Return number of src bytes skipped
cld2/internal/utf8statetable.cc:625
↓ 1 callers
Function
DoTLDLookup
Binary lookup on tld
cld2/internal/compact_lang_det_hint_code.cc:1027
↓ 1 callers
Method
Dump
cld2/internal/tote.cc:252
↓ 1 callers
Function
DumpCLDLangPriors
Make printable string of priors
cld2/internal/compact_lang_det_hint_code.cc:1510
↓ 1 callers
Function
DumpChunkSummary
Move this verbose debugging output to debug.cc eventually
cld2/internal/scoreonescriptspan.cc:636
↓ 1 callers
Function
DumpHitBuffer
cld2/internal/scoreonescriptspan.cc:561
↓ 1 callers
Function
DumpLinearBuffer
cld2/internal/scoreonescriptspan.cc:613
↓ 1 callers
Function
EncodingFromName
bindings/encodings.cc:119
↓ 1 callers
Function
ExtDetectLanguageSummaryCheckUTF8
Use this one. Hints are collected into a struct. Flags are passed in (normally zero). Also returns 3 internal language scores as a ratio to normal s
cld2/internal/compact_lang_det.cc:317
↓ 1 callers
Method
Find
Find subscript of a given packed language, or -1
cld2/internal/tote.cc:178
↓ 1 callers
Function
FindBestProb3Match
For constructing tables Given a vector of 3 probabilities 1..12, find subscript of best table match. Minimizes RMS error Brute-force version
cld2/internal/cldutil_offline.cc:137
↓ 1 callers
Function
FindEqualSign
cld2/internal/compact_lang_det_hint_code.cc:1269
↓ 1 callers
Function
FindQuoteEnd
Find closing quot/apos. Also stop on = > < and & (simplistic parsing)
cld2/internal/compact_lang_det_hint_code.cc:1255
↓ 1 callers
Function
FindQuoteStart
Find opening quote or apostrophe, skipping spaces Note: this is all somewhat insensitive to mismatched quotes
cld2/internal/compact_lang_det_hint_code.cc:1244
↓ 1 callers
Function
FindTagEnd
Find closing '>' for HTML tag. Also stop on < and & (simplistic parsing)
cld2/internal/compact_lang_det_hint_code.cc:1231
↓ 1 callers
Function
FindTagStart
Find opening '<' for HTML tag Note: this is all somewhat insensitive to mismatched quotes
cld2/internal/compact_lang_det_hint_code.cc:1209
↓ 1 callers
Function
FinishHtmlOut
cld2/internal/cld2_unittest_full.cc:365
↓ 1 callers
Function
FinishHtmlOut
cld2/internal/cld2_unittest.cc:279
↓ 1 callers
Function
FinishResult
cld2/internal/scoreutf8text.cc:291
↓ 1 callers
Function
FinishResultVector
Extend results to fully cover the [lo..hi) range
cld2/internal/compact_lang_det_impl.cc:1688
↓ 1 callers
Function
FlagSqueeze
cld2/internal/compact_lang_det_impl.cc:434
↓ 1 callers
Method
Flush
cld2/internal/offsetmap.cc:158
↓ 1 callers
Function
GetBiAt
Debug output string of one bigram
cld2/internal/debug.cc:41
↓ 1 callers
Function
GetBiHits
Score up to 64KB of a single script span, doing both delta-bi and distinct bis in one pass
cld2/internal/cldutil.cc:248
↓ 1 callers
Function
GetLangScript
Return language and script from parsed line or defaults
cld2/internal/cld2_do_score.cc:107
↓ 1 callers
Function
GetLangTagsFromHtml
cld2/internal/compact_lang_det_hint_code.cc:1557
↓ 1 callers
Function
GetOctaAt
Debug output string of one octagram, including underscores
cld2/internal/debug.cc:61
↓ 1 callers
Function
GetOctaHits
Score up to 64KB of a single script span, doing both delta-octa and distinct words in one pass
cld2/internal/cldutil.cc:416
↓ 1 callers
Method
GetOneScriptSpanLower
Copy next run of same-script non-tag letters to buffer [NUL terminated] Force Latin, Cyrillic, Greek scripts to be lowercase Buffer ALWAYS has leading
cld2/internal/getonescriptspan.cc:1061
↓ 1 callers
Function
GetPlainEscapedText
cld2/internal/debug.cc:209
↓ 1 callers
Function
GetQuadAt
Debug output string of one quadgram, including underscores
cld2/internal/debug.cc:50
↓ 1 callers
Function
GetQuadHits
Score up to 64KB of a single script span in one pass Make a dummy entry off the end to calc length of last span Return offset of first unused input by
cld2/internal/cldutil.cc:315
↓ 1 callers
Method
GetScoreCount
cld2/internal/tote.h:45
← previous
next →
101–200 of 421, ranked by callers