code stringlengths 3 6.57k |
|---|
self.traverse(c) |
apply(self) |
self.traverse(self.document) |
setup(app) |
app.add_transform(AutoStructify) |
app.add_transform(ProcessLink) |
__init__(self) |
json.dumps(x) |
encode("utf-8") |
send_message(self, user, event, partition) |
bytes(user, "utf-8") |
self.producer.flush() |
__init__(self) |
json.loads(x.decode("utf-8") |
kafka_close(self) |
self.consumer.close(autocommit=False) |
current_possion(self, partition) |
TopicPartition(self.topic, partition) |
self.consumer.position(tp) |
assign_partition(self, partition) |
TopicPartition(self.topic, partition) |
self.consumer.assign([tp]) |
seek_message(self, partition, offset_start) |
TopicPartition(self.topic, partition) |
self.consumer.seek(tp, offset_start) |
get_offset_and_timestamp(self, tp, timestamp_start, timestamp_end) |
int(timestamp_start) |
int(timestamp_end) |
list(offset_and_timestamp_start.values() |
list(offset_and_timestamp_end.values() |
get_offset(self, partition, timestamp_start, timestamp_end) |
TopicPartition(self.topic, partition) |
self.get_offset_and_timestamp(tp, timestamp_start, timestamp_end) |
Exception("could not found offset and timestamp") |
commands() |
env.PATH.append(os.path.join(applications_path, "powershell", "%s"%version) |
replace('/', os.sep) |
resized_dataset(Dataset) |
__init__(self, dataset, transform=None, start=None, end=None, resize=None) |
dataset.__len__() |
range(start, end) |
self.data.append((*dataset.__getitem__(i) |
range(start, end) |
dataset.__getitem__(i) |
self.data.append((F.center_crop(F.resize(item[0],resize,Image.BILINEAR) |
__len__(self) |
len(self.data) |
__getitem__(self, idx) |
return (self.transform(self.data[idx][0]) |
__init__(self, val) |
buildTree(self, inorder, postorder) |
genTree(inorder,postorder) |
len(inorder) |
TreeNode(root_val) |
inorder.index(root_val) |
len(postorder) |
len(left_inorder) |
genTree(left_inorder, left_postorder) |
len(right_inorder) |
genTree(right_inorder, right_postorder) |
genTree(inorder, postorder) |
load_etf() |
etf_data.set_index(["tdate", "etf_code", "data_name"]) |
unstack() |
unstack() |
load_macro_data() |
pd.read_csv('์ธ๋ถ๋ฐ์ดํฐ/macro_final.csv', index_col='Item Name') |
pd.to_datetime(macro_data.index) |
macro_data.fillna(method='ffill') |
macro_data.resample('m') |
last() |
macro_data.resample('m') |
first() |
G (2G*8) |
G (2G*8) |
load_wics_data() |
process_wics_data("./์ธ๋ถ๋ฐ์ดํฐ/ETF๋ณ ์
์ข
exposure.csv") |
process_wics_data("./์ธ๋ถ๋ฐ์ดํฐ/WICS ์
์ข
๋ณ ํฌ์์ ๋ณด ๋ฐ์ดํฐ.csv") |
T.drop_duplicates() |
features_from_wics(wics) |
load_wics_data() |
wics.xs("์ข
๊ฐ์ง์", level=1, axis=1) |
get_moving_features(wics_price, type='price') |
wics.xs("๊ฑฐ๋๋๊ธ", level=1, axis=1) |
get_moving_features(wics_trd_volume, type='volume') |
wics.xs("๊ฐ์ธ ์๋งค์๋๊ธ(์ผ๊ฐ) |
fillna(0) |
get_moving_features(wics_retail_volume, type='volume') |
wics.xs("์ธ๊ตญ์ธ์ดํฉ๊ณ์๋งค์๋๊ธ(์ผ๊ฐ) |
fillna(0) |
get_moving_features(wics_for_volume, type='volume') |
wics.xs("๊ธฐ๊ด ์๋งค์๋๊ธ(์ผ๊ฐ) |
fillna(0) |
get_moving_features(wics_inst_volume, type='volume') |
wics.xs("P/E(FY0) |
wics_pe.resample('M') |
last() |
apply(lambda X: minmaxscale(X) |
wics.xs("P/E(Fwd.12M) |
get_moving_features(wics_fwd_pe, type='fwd') |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.