原创 Biological Pathways 生物途徑(通路)

Biological Pathways A biological pathway is a series of interactions among molecules in a cell that leads to a certain

原创 【算法】dynamic programming (2)最長公共子序列:遞歸(自頂向下)+備忘錄+輸出結果字符串、編輯距離,加權編輯距離

1. 遞歸+備忘錄的方式寫LCS 不允許使用for和while循環 1.1 只輸出最長的值 1.2 使用備忘錄 memo = [[0 for j in range(len(s2)+1)] for i in range(len(s1)+

原创 【Flask】__init__.py 的異樣導包和導數據_(:з」∠)_

因爲 Flask啓動的 地方是 __init__.py now = os.path.dirname(os.path.abspath(__file__)) cha = pd.read_csv(now+'/sugar.csv') 但是Pyt

原创 【Dash】在回調的時候如何實現多個Output

參考自:Multiple-Outputs-in-Dash-Now-Available Features(特性) Use a list/tuple of Output as output in callbacks. Return a tup

原创 【Python】當你的Python報錯 import moudle error; cannot import name 'xxx' from 'xxx'

同樣一個項目,一個不報錯,一個報import moudle error; python, you fxxking bitch! 後來我才知道 問題在於 在其中一個項目中有一個__init__.py,而另一個沒有; 參考自:refer

原创 【NLP】把stanford CoreNLP移植到服務器上需要用到的一些雜七雜八的東西

關於殺進程 netstat -tunlp|grep 9000 kill -9 進程ID 關於stanford CoreNLP 至少需要4G的運行內存 java -mx4g -cp "*" edu.stanford.nlp.pipeline

原创 【英語】Literally和Figuratively的區別

之前一直看himym裏面Ted糾Robin關於literally和figuratively的錯誤。 然後昨天看了一個採訪,底下的評論說:“但是他們這次真的用對了literally和figuratively” literally本意爲“字面

原创 【英語】Academic English Writing

1. Interrogative sentences are often discouraged in academic writing.  2.來自:https://targetenglish.wordpress.com/2014/02

原创 【Dash】熱力圖(Heatmap)

案例1:https://github.com/balajiciet/daypart 對案例1的講解:https://medium.com/@balajiciet/dashboard-interactive-heatmap-visualiz

原创 如何把Dash項目(Python項目)部署到服務器上

參考鏈接: basic-flask-website-tutorial deploy-vps-dash-data-visualization 首先要有一個服務器: 登錄服務器 更新 sudo apt-get update && sudo

原创 D3小問題(四)爲座標軸添加過渡效果

爲座標軸添加過渡效果 D3 rescale axis example Animating between scale !!!making-dynamic-scales-and-axes!!! 製作動態比例 簡單的D3線性刻度尺:是成比例的

原创 【算法】計算時間複雜度

O(n) 小於等於 o(n) 小於 Ω(n) 大於等於 ω(n) 大於 Θ(n) 等於 直接判斷時間複雜度 Q1: 其中,所以f is in Θ(n) Q2: 其中,所以f is in O(n) 根據代碼判斷時間複雜度

原创 【NLP】手動下載nltk相關數據/nltk punkt

我佛了 一個文件下半個小時還下不下來? 解壓到固定的目錄,比如在我的服務器上是root/nltk_data下... 參考自:https://medium.com/@satorulogic/how-to-manually-download-

原创 【算法】動態規劃(1)

dbq我又開始學算法了 這次是 毫無壓力的學 我覺得很開心~  以下都來自於我的的humble opinion~ 在DP中,遞歸是top-down,填表是bottom-up. 我之前一直都沒有搞懂過,自頂向下和自底向上的區別;(可能我

原创 【算法】貪心

活動安排 問題描述:給很多電影的開始和結束時間,看每個電影之間需要間隔3分鐘,返回看盡可能多的電影的個數。編寫函數max_num_movies(movie_list),movie_list 是(start_time, end_time)