cur前缀_前缀

)。单词中位于词根前面的部分就是前缀。

前缀,可以改变单词的意思。

常见的前缀有如下几类:第一类:表示正负(或增减)的,如:

un- in- im- il- ir- non-  mis-  mal-  dis- anti- de-  under- re-

over-

等;第二类表示尺寸的,如:

semi-  equi-  mini-  micro-  macro-  mega-

等;第三类表示位置关系,如:

inter-  super-  trans-  ex-  extra-  sub-  infra-  peri-

等;第四类表示时间和次序,

如:

ante-  pre-  prime-  post-  retro-

等;

五类表示数字,如:

semi-  mono-  bi-  tri-  quad-  penta-  hex-  sept(em)-  oct-  dec- multi-

等;其它类别,如:

pro-  auto-  co-  con-

等。

常见英语前缀

一.表示否定的前缀

1

dis

-加在名词、形容词,动词之前。

disadvantage

(缺点)

dishonorable

(不光彩的)

disagree

(不同意)

2

in-

加在形容词,名词之前

incorrect

(不正确的),

inability

(无能,无力),

inaccurate

(不准确的)

3

im-

加在字母

m,b,p

之前

impossible

(不顺能的),

impolite

(不礼貌的),

impudence

(厚颜无耻)

4

il-

加在以

1

开头的词前

illegal

(非法的),

illiterate

(文盲的,无文化的)

illogical

(不合逻辑的)

5

ir-

加在以

r

开头的词前

irregular

(不稳定的),

irresistable

(不可抵抗的),

irresolvable

(不能分解的,不能解决的)

6

un-

加在名词,形容词,副词之前

unfinished

(未完成的)

undoubted

(无疑的)

unemployment

(失业)

7

non-

加在形容词,名词前

non-existence

(不存在),

non-essential

(不主要的),

non-electrical

(非电的)

8

mis

-加在动词、名词之前

misunderstand

(误解),

misjudge

(误判),

misleading

(误导),

misfortune

(不幸)

9

dis-

加地动词之前

disappear

(消失),

disarm

(解除武装),

disconnect

(失去联系)

10

de-

加在名词,形容词之前

demobilize(

遣散;使

复员

) decolor (

脱色

,

漂白

)

11

anti-

加在名词、形容词之前

anti-Japanese

(抗日战争),

anti-social

(厌恶社会的,反社会的),

antidite

(解毒药)

12

counter-

加在名词、动词前

counterattack

(反攻,反击),

counteract

(抵抗,阻碍)

counterrevolution

(反革命)

解释一下这段代码 def add_seq_to_prefix_tree(self, root_node, cluster: LogCluster): token_count = len(cluster.log_template_tokens) token_count_str = str(token_count) if token_count_str not in root_node.key_to_child_node: first_layer_node = Node() root_node.key_to_child_node[token_count_str] = first_layer_node else: first_layer_node = root_node.key_to_child_node[token_count_str] cur_node = first_layer_node if token_count == 0: cur_node.cluster_ids = [cluster.cluster_id] return current_depth = 1 for token in cluster.log_template_tokens: if current_depth >= self.max_node_depth or current_depth >= token_count: new_cluster_ids = [] for cluster_id in cur_node.cluster_ids: if cluster_id in self.id_to_cluster: new_cluster_ids.append(cluster_id) new_cluster_ids.append(cluster.cluster_id) cur_node.cluster_ids = new_cluster_ids break if token not in cur_node.key_to_child_node: if self.parametrize_numeric_tokens and self.has_numbers(token): if self.param_str not in cur_node.key_to_child_node: new_node = Node() cur_node.key_to_child_node[self.param_str] = new_node cur_node = new_node else: cur_node = cur_node.key_to_child_node[self.param_str] else: if self.param_str in cur_node.key_to_child_node: if len(cur_node.key_to_child_node) < self.max_children: new_node = Node() cur_node.key_to_child_node[token] = new_node cur_node = new_node else: cur_node = cur_node.key_to_child_node[self.param_str] else: if len(cur_node.key_to_child_node) + 1 < self.max_children: new_node = Node() cur_node.key_to_child_node[token] = new_node cur_node = new_node elif len(cur_node.key_to_child_node) + 1 == self.max_children: new_node = Node() cur_node.key_to_child_node[self.param_str] = new_node cur_node = new_node else: cur_node = cur_node.key_to_child_node[self.param_str] else: cur_node = cur_node.key_to_child_node[token] current_depth += 1
最新发布
03-23
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值