This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!--V 1.0 � Stand: 01.08.2020 | |
################################ | |
Mod by DonnyBresko | |
################################ | |
--> | |
<ModOps> | |
<!--#### CORE ####--> | |
<ModOp Type="addNextSibling" GUID='11703'><!--ADD NEW ITEM [PALLETS]--> | |
<Asset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ModOps> | |
<ModOp Type="add" Path="/TextExport/Texts"> | |
<Text> | |
<GUID>601136120</GUID> | |
<Text>天然氣廠</Text> | |
</Text> | |
<Text> | |
<GUID>601136110</GUID> | |
<Text>天然氣廠</Text> | |
</Text> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from math import log | |
import bisect | |
from collections import Counter | |
class DiscretizationMDLP(object): | |
def __init__(self, x, y): | |
if len(x) != len(y): | |
raise Exception("The length of x must be equal to the length of y.") | |
# sort first | |
self.data = sorted(zip(*[x, y]), key=lambda x: x[0]) |