소스 검색

Merge pull request #332 from visuddhinanda:master

提高效能
Bhikkhu-Kosalla 5 년 전
부모
커밋
0d08ea2de7
1개의 변경된 파일7개의 추가작업 그리고 1개의 파일을 삭제
  1. 7 1
      app/dict/comp_csv.php

+ 7 - 1
app/dict/comp_csv.php

@@ -58,7 +58,13 @@ while($word = $redis->hGet("pali://wordindex.hash",$start))
 
         foreach ($arrword as $oneword) {
 			$result = array(); //全局变量,递归程序的输出容器
-			mySplit2($oneword, 0, false, 0.2, 0.9, 0, true, false);
+			if(mb_strlen($oneword)>35){
+				mySplit2($oneword, 0, true, 0.8, 0.9, 0, true, false);
+			}
+			else{
+				mySplit2($oneword, 0, false, 0.8, 0.9, 0, true, false);
+			}
+			
 			if(count($result)<3){
 				mySplit2($oneword, 0, false, 0.2, 0.8, 0, true, true);
 				if (isset($_POST["debug"])) {