/* 自定義代碼塊樣式 */

herrDeng網內搜尋

自訂搜尋

Ads

顯示具有 python 標籤的文章。 顯示所有文章
顯示具有 python 標籤的文章。 顯示所有文章

2026年9月4日 星期五

0ms C++ Py3 |Suffix MIN與Prefix MAX解Leetcode 3903, 3904 Smallest Stable Index


0ms C++ Py3 Suffix MIN與Prefix MAX解Leetcode 3903, 3904  Smallest Stable Index
使用一個名為 suf 的陣列來記錄字尾最小值(suffix min)。
接著進行動態Prefix MAX(字首最大值)的計算,以找出何時滿足Max-suf[i] leq k!
[Py3  code請進]

2026年9月2日 星期三

0ms C++ 1-line Py3解Leetcode 3875, 3876 Construct Uniform Parity Array


0ms C++ 1-line Py3解Leetcode 3875, 3876  Construct Uniform Parity Array
一次解Leetcode 3875, 3876,code很簡單,重點是邏輯。
Solving LeetCode 3875 & 3876 together. Simple code, focus is on the logic.

2026年8月25日 星期二

登1076大屯山黑柴:YOLOE又誤判了!不是雪納瑞 (Kein Schnauzer!😂)


登1076的大屯山黑柴:『我不是雪納瑞』YOLOE又誤判了
Schnauzer,除了是指雪納瑞之外,在德文又指鬍鬚
用三種YOLO 模型:

2026年8月20日 星期四

0ms Branchless Leetcode 3069 | Py3 & C++ 高速解法


Py3 CPP 速解3069  Distribute Elements Into Two Arrays I
為什麼要寫branchless code?避免 CPU 的分支預測失敗!當代CPU 會預先猜測條件判斷(如 if-else)的結果並繼續往下執行。當預測成功時,猜對了效能極佳,猜錯了會造成時間上的懲罰。利用容器index的True or False達成Branchless code!
[C++ Python3 codes請進]

2026年8月19日 星期三

好療癒的畫面, 黑柴爽快地被梳狗毛、清耳朵與YOLO辨識


黑柴 爽快地被梳狗毛、清耳朵與 #YOLO 辨識
使用之AI: yolo26-x  yoloe-x26 openvocabulary
0-shot 
減少太多的的辨識框,零樣本偵測僅標示:
"black and tan shiba inu", "comb", "brush","slipper","handkerchief"

2026年8月16日 星期日

YOLOE 辨識:黑柴、Panther 與 T34 戰車,誰變成了捕鼠器?

yoloe AI誤判成捕鼠器,黑柴與模型戰車T34 panther
用能辨識1203種的物件的yoloe-pf辨識,1/35的 蘇聯戰車 t34成捕鼠器(Moustrap)、德軍豹式戰車成模型車。
改用YOLOE open vocabulary黑柴是黑柴、二戰戰車是戰車,連微小的模型士兵也能辨識為miniature person

2026年8月15日 星期六

0ms C++ Py3 1 line 解 Leetcode 3702 sequence With Non Zero Bitwise XOR


0ms C++ Py3 1 line 解 Leetcode 3702  sequence With Non Zero Bitwise XOR
迴圈解不稀奇,Python一行解也不稀奇,C++一行解就很少了!
[C++ Py3 一行解請進 👇]

2026年8月12日 星期三

C++ Py3|Sliding window hashmap解Leetcode 2958 Length of Longest Subarray With at Most K


Beat 99.89% C++ Py3|Sliding window hashmap解Leetcode 2958 Length of Longest Subarray With at Most K
一陣子沒出Leetcode解題長片。這題其實很標準2958. Length of Longest Subarray With at Most K Frequency,適合練習sliding window+ hash map ! 客製化的hash map似乎是overkilling

2026年8月10日 星期一

黑柴遇見凶悍的白鵝 AI辨識


#黑柴犬 (#kuroshiba ) 遇見凶悍的白鵝 #YOLO/ #YOLOE AI識
採用 YOLO26 與 YOLOE #零樣本測試
open vocabulary設為:
"black shiba","white goose","car","person"

2026年8月8日 星期六

2026年8月6日 星期四

orange🍊?但我這裡只有穿橘色背帶(Dog Harness)的黑柴!YOLOE 零樣本辨識挑戰


#黑柴 穿新橘色#狗背帶 #YOLOE #零樣本測試
黑柴很不喜歡他的新衣,費了很大勁,才穿上,帶他行走。

這次open vocabulary的設定
model.set_classes([
    "orange dog harness",       # 橘色狗背帶(核心目標)
    "black and tan shiba inu", # 正確強化的黑柴描述
    "black and tan husky" #混淆用
.....
看看會不會誤判

2026年7月30日 星期四

2026年7月29日 星期三

2026年7月27日 星期一

0ms 速解Leetcode 1464 最大的乘積:別只會用 Sort!試試Py nlargest, C++ nth_element


0ms|1 line Py3 #nlargest #cpp #nth_element 速解 #Leetcode1464 最大的乘積
Python 1行解用heapq.nlargest。C++2行解用nth_element,都是linear 0ms
[C++, Py3 codes請進]

2026年7月25日 星期六

Related Posts Plugin for WordPress, Blogger...

熱門文章