mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-03-06 18:26:33 +00:00
@@ -164,7 +164,7 @@ namespace NLangDetect.Core
|
||||
|
||||
public string Detect()
|
||||
{
|
||||
var probabilities = GetProbabilities();
|
||||
List<Language> probabilities = GetProbabilities();
|
||||
|
||||
return
|
||||
probabilities.Count > 0
|
||||
@@ -241,7 +241,7 @@ namespace NLangDetect.Core
|
||||
{
|
||||
CleanText();
|
||||
|
||||
var ngrams = ExtractNGrams();
|
||||
List<string> ngrams = ExtractNGrams();
|
||||
|
||||
if (ngrams.Count == 0)
|
||||
{
|
||||
@@ -332,7 +332,7 @@ namespace NLangDetect.Core
|
||||
return;
|
||||
}
|
||||
|
||||
var langProbMap = _wordLangProbMap[word];
|
||||
ProbVector langProbMap = _wordLangProbMap[word];
|
||||
double weight = alpha / _BaseFreq;
|
||||
|
||||
for (int i = 0; i < prob.Length; i++)
|
||||
|
||||
@@ -150,7 +150,7 @@ namespace Emby.Server.Implementations.TextEncoding
|
||||
public CharacterEncoding DetectEncoding(byte[] buffer, int size)
|
||||
{
|
||||
// First check if we have a BOM and return that if so
|
||||
var encoding = CheckBom(buffer, size);
|
||||
CharacterEncoding encoding = CheckBom(buffer, size);
|
||||
if (encoding != CharacterEncoding.None)
|
||||
{
|
||||
return encoding;
|
||||
|
||||
@@ -84,7 +84,7 @@ namespace UniversalDetector.Core
|
||||
}
|
||||
else if (j != activeSM)
|
||||
{
|
||||
var t = codingSM[activeSM];
|
||||
CodingStateMachine t = codingSM[activeSM];
|
||||
codingSM[activeSM] = codingSM[j];
|
||||
codingSM[j] = t;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user