mdbq 2.6.1__py3-none-any.whl → 2.6.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mdbq/aggregation/aggregation.py +17 -15
- mdbq/aggregation/query_data.py +132 -107
- mdbq/clean/clean_upload.py +129 -99
- mdbq/dataframe/converter.py +2 -2
- {mdbq-2.6.1.dist-info → mdbq-2.6.3.dist-info}/METADATA +1 -1
- {mdbq-2.6.1.dist-info → mdbq-2.6.3.dist-info}/RECORD +8 -8
- {mdbq-2.6.1.dist-info → mdbq-2.6.3.dist-info}/WHEEL +0 -0
- {mdbq-2.6.1.dist-info → mdbq-2.6.3.dist-info}/top_level.txt +0 -0
mdbq/clean/clean_upload.py
CHANGED
@@ -89,13 +89,13 @@ class DataClean:
|
|
89
89
|
path = self.path
|
90
90
|
report_names = [
|
91
91
|
{
|
92
|
-
'文件简称': '商品排行', # 文件名中包含的字符
|
93
|
-
'数据库名': '
|
92
|
+
'文件简称': '商品排行_', # 文件名中包含的字符
|
93
|
+
'数据库名': '生意参谋3',
|
94
94
|
'集合名称': '商品排行',
|
95
95
|
},
|
96
96
|
{
|
97
|
-
'文件简称': '店铺来源_来源构成_
|
98
|
-
'数据库名': '
|
97
|
+
'文件简称': '店铺来源_来源构成_', # 文件名中包含的字符
|
98
|
+
'数据库名': '生意参谋3',
|
99
99
|
'集合名称': '店铺流量来源构成',
|
100
100
|
},
|
101
101
|
]
|
@@ -126,7 +126,7 @@ class DataClean:
|
|
126
126
|
is_continue = True
|
127
127
|
if not is_continue:
|
128
128
|
continue
|
129
|
-
if name.endswith('.xls') and '商品排行_
|
129
|
+
if name.endswith('.xls') and '商品排行_' in name:
|
130
130
|
df = pd.read_excel(os.path.join(root, name), header=4)
|
131
131
|
if len(df) == 0:
|
132
132
|
print(f'{name} 报表数据为空')
|
@@ -135,11 +135,12 @@ class DataClean:
|
|
135
135
|
df.replace(to_replace=[','], value='', regex=True, inplace=True)
|
136
136
|
df.rename(columns={'统计日期': '日期', '商品ID': '商品id'}, inplace=True)
|
137
137
|
shop_name = re.findall(r'_([\u4e00-\u9fffA-Za-z]+店)', name)[0]
|
138
|
-
|
138
|
+
if '店铺名称' not in df.columns.tolist():
|
139
|
+
df.insert(loc=1, column='店铺名称', value=shop_name)
|
139
140
|
new_name = f'py_xg_{os.path.splitext(name)[0]}.csv'
|
140
141
|
self.save_to_csv(df, root, new_name, encoding='utf-8_sig')
|
141
142
|
os.remove(os.path.join(root, name))
|
142
|
-
elif name.endswith('.csv') and '_来源构成_
|
143
|
+
elif name.endswith('.csv') and '_来源构成_' in name:
|
143
144
|
df = pd.read_csv(os.path.join(root, name), encoding='utf-8_sig', header=0, na_filter=False)
|
144
145
|
new_name = f'py_xg_{os.path.splitext(name)[0]}.csv'
|
145
146
|
self.save_to_csv(df, root, new_name, encoding='utf-8_sig')
|
@@ -225,67 +226,67 @@ class DataClean:
|
|
225
226
|
report_names = [
|
226
227
|
{
|
227
228
|
'文件简称': 'tg_report_主体报表',
|
228
|
-
'数据库名': '推广数据
|
229
|
+
'数据库名': '推广数据2',
|
229
230
|
'集合名称': '主体报表',
|
230
231
|
},
|
231
232
|
{
|
232
233
|
'文件简称': 'tg_report_创意报表_创意',
|
233
|
-
'数据库名': '推广数据
|
234
|
+
'数据库名': '推广数据2',
|
234
235
|
'集合名称': '创意报表_创意',
|
235
236
|
},
|
236
237
|
{
|
237
238
|
'文件简称': 'tg_report_创意报表_素材',
|
238
|
-
'数据库名': '推广数据
|
239
|
+
'数据库名': '推广数据2',
|
239
240
|
'集合名称': '创意报表_素材',
|
240
241
|
},
|
241
242
|
{
|
242
243
|
'文件简称': 'tg_report_单元报表',
|
243
|
-
'数据库名': '推广数据
|
244
|
+
'数据库名': '推广数据2',
|
244
245
|
'集合名称': '单元报表',
|
245
246
|
},
|
246
247
|
{
|
247
248
|
'文件简称': 'tg_report_地域报表_省份',
|
248
|
-
'数据库名': '推广数据
|
249
|
+
'数据库名': '推广数据2',
|
249
250
|
'集合名称': '地域报表_省份',
|
250
251
|
},
|
251
252
|
{
|
252
253
|
'文件简称': 'tg_report_地域报表_城市',
|
253
|
-
'数据库名': '推广数据
|
254
|
+
'数据库名': '推广数据2',
|
254
255
|
'集合名称': '地域报表_城市',
|
255
256
|
},
|
256
257
|
{
|
257
258
|
'文件简称': 'tg_report_关键词报表',
|
258
|
-
'数据库名': '推广数据
|
259
|
+
'数据库名': '推广数据2',
|
259
260
|
'集合名称': '关键词报表',
|
260
261
|
},
|
261
262
|
{
|
262
263
|
'文件简称': 'tg_report_计划报表',
|
263
|
-
'数据库名': '推广数据
|
264
|
+
'数据库名': '推广数据2',
|
264
265
|
'集合名称': '计划报表',
|
265
266
|
},
|
266
267
|
{
|
267
268
|
'文件简称': 'tg_report_权益报表',
|
268
|
-
'数据库名': '推广数据
|
269
|
+
'数据库名': '推广数据2',
|
269
270
|
'集合名称': '权益报表',
|
270
271
|
},
|
271
272
|
{
|
272
273
|
'文件简称': 'tg_report_人群报表',
|
273
|
-
'数据库名': '推广数据
|
274
|
+
'数据库名': '推广数据2',
|
274
275
|
'集合名称': '人群报表',
|
275
276
|
},
|
276
277
|
{
|
277
278
|
'文件简称': 'tg_report_营销场景报表',
|
278
|
-
'数据库名': '推广数据
|
279
|
+
'数据库名': '推广数据2',
|
279
280
|
'集合名称': '营销场景报表',
|
280
281
|
},
|
281
282
|
{
|
282
283
|
'文件简称': 'tg_report_超级直播报表_人群',
|
283
|
-
'数据库名': '推广数据
|
284
|
+
'数据库名': '推广数据2',
|
284
285
|
'集合名称': '超级直播',
|
285
286
|
},
|
286
287
|
{
|
287
288
|
'文件简称': 'tg_report_品销宝_明星店铺',
|
288
|
-
'数据库名': '推广数据
|
289
|
+
'数据库名': '推广数据2',
|
289
290
|
'集合名称': '品销宝',
|
290
291
|
}
|
291
292
|
]
|
@@ -318,9 +319,9 @@ class DataClean:
|
|
318
319
|
continue
|
319
320
|
# 区分淘宝和天猫的报表
|
320
321
|
if '万里马官方旗舰店' in name:
|
321
|
-
|
322
|
+
pass
|
322
323
|
elif '万里马官方企业店' in name:
|
323
|
-
db_name =
|
324
|
+
db_name = '推广数据_淘宝店'
|
324
325
|
else:
|
325
326
|
print(f'报表名称错误,不属于天猫/淘宝店:{name}')
|
326
327
|
continue
|
@@ -387,22 +388,22 @@ class DataClean:
|
|
387
388
|
report_names = [
|
388
389
|
{
|
389
390
|
'文件简称': 'baobei',
|
390
|
-
'数据库名': '
|
391
|
+
'数据库名': '生意经2',
|
391
392
|
'集合名称': '宝贝指标',
|
392
393
|
},
|
393
394
|
{
|
394
395
|
'文件简称': 'order',
|
395
|
-
'数据库名': '
|
396
|
+
'数据库名': '生意经2',
|
396
397
|
'集合名称': '订单指标',
|
397
398
|
},
|
398
399
|
{
|
399
400
|
'文件简称': '省份城市分析',
|
400
|
-
'数据库名': '
|
401
|
+
'数据库名': '生意经2',
|
401
402
|
'集合名称': '省份城市分析',
|
402
403
|
},
|
403
404
|
{
|
404
405
|
'文件简称': '店铺销售指标',
|
405
|
-
'数据库名': '
|
406
|
+
'数据库名': '生意经2',
|
406
407
|
'集合名称': '店铺销售指标',
|
407
408
|
},
|
408
409
|
]
|
@@ -783,6 +784,29 @@ class DataClean:
|
|
783
784
|
def sp_scene_clean(self, path=None, is_except=[]):
|
784
785
|
if not path:
|
785
786
|
path = self.path
|
787
|
+
report_names = [
|
788
|
+
{
|
789
|
+
'文件简称': '商品素材_', # 文件名中包含的字符
|
790
|
+
'数据库名': '属性设置3',
|
791
|
+
'集合名称': '商品素材中心',
|
792
|
+
},
|
793
|
+
{
|
794
|
+
'文件简称': '商品类目属性_', # 文件名中包含的字符
|
795
|
+
'数据库名': '属性设置3',
|
796
|
+
'集合名称': '商品类目属性',
|
797
|
+
},
|
798
|
+
{
|
799
|
+
'文件简称': '商品主图视频_', # 文件名中包含的字符
|
800
|
+
'数据库名': '属性设置3',
|
801
|
+
'集合名称': '商品主图视频',
|
802
|
+
},
|
803
|
+
{
|
804
|
+
'文件简称': '商品sku属性_', # 文件名中包含的字符
|
805
|
+
'数据库名': '属性设置3',
|
806
|
+
'集合名称': '商品sku',
|
807
|
+
},
|
808
|
+
]
|
809
|
+
|
786
810
|
for root, dirs, files in os.walk(path, topdown=False):
|
787
811
|
for name in files:
|
788
812
|
if '~$' in name or '.DS' in name or '.localized' in name or '.jpg' in name or '.png' in name:
|
@@ -800,21 +824,29 @@ class DataClean:
|
|
800
824
|
continue
|
801
825
|
db_name = None # 初始化参数
|
802
826
|
collection_name = None
|
827
|
+
for item in report_names:
|
828
|
+
if item['文件简称'] in name:
|
829
|
+
db_name = item['数据库名']
|
830
|
+
collection_name = item['集合名称']
|
831
|
+
is_continue = True
|
832
|
+
if not is_continue:
|
833
|
+
continue
|
803
834
|
|
804
835
|
if name.endswith('.xlsx') and '商品素材_' in name:
|
805
836
|
shop_name = re.findall(r'_([\u4e00-\u9fffA-Za-z]+店)_', name)[0]
|
806
837
|
df = pd.read_excel(os.path.join(root, name), header=0)
|
807
|
-
|
838
|
+
if '日期' not in df.columns.tolist():
|
839
|
+
df.insert(loc=0, column='日期', value=datetime.datetime.today().strftime('%Y-%m-%d'))
|
840
|
+
if '店铺名称' not in df.columns.tolist():
|
841
|
+
df.insert(loc=1, column='店铺名称', value=shop_name)
|
808
842
|
new_name = f'py_xg_{name}'
|
809
843
|
df.to_excel(os.path.join(upload_path, new_name),
|
810
844
|
index=False, header=True, engine='openpyxl', freeze_panes=(1, 0))
|
811
|
-
if '官方旗舰店' in name:
|
812
|
-
db_name = '属性设置3'
|
813
|
-
collection_name = '商品素材_天猫'
|
814
|
-
elif '官方企业店' in name:
|
815
|
-
db_name = '属性设置3'
|
816
|
-
collection_name = '商品素材_淘宝'
|
817
845
|
os.remove(os.path.join(root, name))
|
846
|
+
elif name.endswith('.csv') and ('商品类目属性' in name or '商品主图视频' in name or '商品sku属性' in name):
|
847
|
+
df = pd.read_csv(os.path.join(root, name), encoding='utf-8_sig', header=0, na_filter=False)
|
848
|
+
new_name = f'py_xg_{os.path.splitext(name)[0]}.csv'
|
849
|
+
os.rename(os.path.join(root, name), os.path.join(root, new_name))
|
818
850
|
|
819
851
|
# 将数据传入 self.datas 等待更新进数据库
|
820
852
|
if not db_name or not collection_name:
|
@@ -881,11 +913,15 @@ class DataClean:
|
|
881
913
|
if 'py_xg' not in name: # 排除非目标文件
|
882
914
|
continue
|
883
915
|
|
884
|
-
if name.endswith('.csv') and '商品排行_
|
885
|
-
t_path = os.path.join(self.source_path, '
|
916
|
+
if name.endswith('.csv') and '商品排行_' in name:
|
917
|
+
t_path = os.path.join(self.source_path, '生意参谋', '商品排行')
|
886
918
|
bib(t_path, _as_month=True)
|
887
|
-
elif name.endswith('.csv') and '店铺来源_来源构成_
|
888
|
-
t_path = os.path.join(self.source_path, '
|
919
|
+
elif name.endswith('.csv') and '店铺来源_来源构成_' in name:
|
920
|
+
t_path = os.path.join(self.source_path, '生意参谋', '店铺流量来源')
|
921
|
+
bib(t_path, _as_month=True)
|
922
|
+
elif name.endswith('.csv') and (
|
923
|
+
'商品类目属性' in name or '商品主图视频' in name or '商品sku属性' in name):
|
924
|
+
t_path = os.path.join(self.source_path, '生意参谋', '商品属性')
|
889
925
|
bib(t_path, _as_month=True)
|
890
926
|
|
891
927
|
def move_dmp(self, path=None, is_except=[]):
|
@@ -915,7 +951,7 @@ class DataClean:
|
|
915
951
|
continue
|
916
952
|
|
917
953
|
if name.endswith('.csv') and '人群属性_万里马官方旗舰店' in name:
|
918
|
-
t_path = os.path.join(self.source_path, '
|
954
|
+
t_path = os.path.join(self.source_path, '达摩盘', '我的人群属性')
|
919
955
|
bib(t_path, _as_month=True)
|
920
956
|
|
921
957
|
|
@@ -1097,10 +1133,10 @@ class DataClean:
|
|
1097
1133
|
t_path = os.path.join(self.source_path, '天猫推广报表', '品销宝', '定向人群报表')
|
1098
1134
|
bib(t_path, _as_month=True)
|
1099
1135
|
elif name.endswith('xlsx') and '商品素材_万里马官方旗舰店' in name:
|
1100
|
-
t_path = os.path.join(self.source_path, '商品素材'
|
1136
|
+
t_path = os.path.join(self.source_path, '商品素材')
|
1101
1137
|
bib(t_path, _as_month=True)
|
1102
1138
|
elif name.endswith('xlsx') and '商品素材_万里马官方企业店' in name:
|
1103
|
-
t_path = os.path.join(self.source_path, '商品素材'
|
1139
|
+
t_path = os.path.join(self.source_path, '商品素材')
|
1104
1140
|
bib(t_path, _as_month=True)
|
1105
1141
|
|
1106
1142
|
# @try_except
|
@@ -1343,6 +1379,51 @@ class DataClean:
|
|
1343
1379
|
df_to_json.as_json_file() # 写入 json 文件, 包含数据的 dtypes 信息
|
1344
1380
|
|
1345
1381
|
|
1382
|
+
def test():
|
1383
|
+
# main_key = '单元报表'
|
1384
|
+
path = f'/Users/xigua/数据中心/原始文件3/天猫推广报表/主体报表'
|
1385
|
+
for root, dirs, files in os.walk(path, topdown=False):
|
1386
|
+
for name in files:
|
1387
|
+
if '~$' in name or '.DS' in name or '.localized' in name or '.jpg' in name or '.png' in name:
|
1388
|
+
continue
|
1389
|
+
# if 'py_xg' in name:
|
1390
|
+
# continue
|
1391
|
+
# if 'TM_旧表_字段' in root:
|
1392
|
+
# continue
|
1393
|
+
|
1394
|
+
if name.endswith('.csv'):
|
1395
|
+
print(name)
|
1396
|
+
df = pd.read_csv(os.path.join(root, name), encoding='utf-8_sig', header=0, na_filter=False)
|
1397
|
+
# if '店铺名称' not in df.columns.tolist():
|
1398
|
+
# df.insert(loc=1, column='店铺名称', value='万里马官方旗舰店')
|
1399
|
+
# df.replace(to_replace=['-'], value=0, regex=False, inplace=True)
|
1400
|
+
# df.replace(to_replace=[','], value='', regex=True, inplace=True)
|
1401
|
+
# if '统计日期' in df.columns.tolist() and '日期' not in df.columns.tolist():
|
1402
|
+
# df.rename(columns={'统计日期': '日期', '商品ID': '商品id'}, inplace=True)
|
1403
|
+
# shop_name = re.findall(r'_([\u4e00-\u9fffA-Za-z]+店)', name)[0]
|
1404
|
+
# df.insert(loc=1, column='店铺名称', value=shop_name)
|
1405
|
+
|
1406
|
+
date_all = re.findall(r'_(\d{4}-\d{2}-\d{2})_', name)[0]
|
1407
|
+
|
1408
|
+
date = re.findall(r'_(\d{4}-\d{2})-\d{2}', name)[0]
|
1409
|
+
|
1410
|
+
new_path = f'/Users/xigua/数据中心/原始文件3/天猫_生意参谋/商品排行/{date}'
|
1411
|
+
# new_path = os.path.join(new_path, date) # 添加 年月分类
|
1412
|
+
if not os.path.exists(new_path):
|
1413
|
+
os.makedirs(new_path, exist_ok=True)
|
1414
|
+
# print(date_all)
|
1415
|
+
|
1416
|
+
new_name = f'py_xg_商品排行_万里马官方旗舰店_{date_all}.csv'
|
1417
|
+
# print(os.path.join(new_path, new_name))
|
1418
|
+
# breakpoint()
|
1419
|
+
df.to_csv(os.path.join(new_path, new_name), encoding='utf-8_sig', index=False, header=True)
|
1420
|
+
# try:
|
1421
|
+
# df.to_excel(os.path.join(new_path, new_name),
|
1422
|
+
# index=False, header=True, engine='openpyxl', freeze_panes=(1, 0))
|
1423
|
+
# except Exception as e:
|
1424
|
+
# print(e)
|
1425
|
+
|
1426
|
+
|
1346
1427
|
def main(service_databases=None, is_mysql=False):
|
1347
1428
|
"""
|
1348
1429
|
is_mysql: 调试时加,False: 是否后续的聚合数据
|
@@ -1389,20 +1470,16 @@ def main(service_databases=None, is_mysql=False):
|
|
1389
1470
|
# 清理所有非聚合数据的库
|
1390
1471
|
optimize_data.op_data(
|
1391
1472
|
db_name_lists=[
|
1392
|
-
'京东数据
|
1473
|
+
'京东数据3',
|
1474
|
+
'属性设置3',
|
1393
1475
|
'推广数据2',
|
1394
|
-
'
|
1395
|
-
'
|
1476
|
+
'生意参谋3',
|
1477
|
+
'推广数据_淘宝店',
|
1478
|
+
'爱库存2'
|
1479
|
+
'生意参谋3',
|
1396
1480
|
'生意经2',
|
1397
|
-
'属性设置2',
|
1398
1481
|
# '聚合数据', # 不在这里清理聚合数据, 还未开始聚合呢
|
1399
|
-
'
|
1400
|
-
'天猫_推广数据3',
|
1401
|
-
'淘宝_推广数据3',
|
1402
|
-
# '市场数据3',
|
1403
|
-
'天猫_生意参谋3',
|
1404
|
-
'天猫_生意经3',
|
1405
|
-
# '淘宝_生意经3',
|
1482
|
+
'达摩盘3',
|
1406
1483
|
],
|
1407
1484
|
days=100,
|
1408
1485
|
is_mongo=True,
|
@@ -1424,53 +1501,6 @@ def main(service_databases=None, is_mysql=False):
|
|
1424
1501
|
)
|
1425
1502
|
|
1426
1503
|
|
1427
|
-
def test():
|
1428
|
-
# main_key = '单元报表'
|
1429
|
-
path = f'/Users/xigua/数据中心/原始文件3/天猫推广报表/主体报表'
|
1430
|
-
for root, dirs, files in os.walk(path, topdown=False):
|
1431
|
-
for name in files:
|
1432
|
-
if '~$' in name or '.DS' in name or '.localized' in name or '.jpg' in name or '.png' in name:
|
1433
|
-
continue
|
1434
|
-
# if 'py_xg' in name:
|
1435
|
-
# continue
|
1436
|
-
# if 'TM_旧表_字段' in root:
|
1437
|
-
# continue
|
1438
|
-
|
1439
|
-
if name.endswith('.csv'):
|
1440
|
-
print(name)
|
1441
|
-
df = pd.read_csv(os.path.join(root, name), encoding='utf-8_sig', header=0, na_filter=False)
|
1442
|
-
# if '店铺名称' not in df.columns.tolist():
|
1443
|
-
# df.insert(loc=1, column='店铺名称', value='万里马官方旗舰店')
|
1444
|
-
# df.replace(to_replace=['-'], value=0, regex=False, inplace=True)
|
1445
|
-
# df.replace(to_replace=[','], value='', regex=True, inplace=True)
|
1446
|
-
# if '统计日期' in df.columns.tolist() and '日期' not in df.columns.tolist():
|
1447
|
-
# df.rename(columns={'统计日期': '日期', '商品ID': '商品id'}, inplace=True)
|
1448
|
-
# shop_name = re.findall(r'_([\u4e00-\u9fffA-Za-z]+店)', name)[0]
|
1449
|
-
# df.insert(loc=1, column='店铺名称', value=shop_name)
|
1450
|
-
|
1451
|
-
date_all = re.findall(r'_(\d{4}-\d{2}-\d{2})_', name)[0]
|
1452
|
-
|
1453
|
-
date = re.findall(r'_(\d{4}-\d{2})-\d{2}', name)[0]
|
1454
|
-
|
1455
|
-
new_path = f'/Users/xigua/数据中心/原始文件3/天猫_生意参谋/商品排行/{date}'
|
1456
|
-
# new_path = os.path.join(new_path, date) # 添加 年月分类
|
1457
|
-
if not os.path.exists(new_path):
|
1458
|
-
os.makedirs(new_path, exist_ok=True)
|
1459
|
-
# print(date_all)
|
1460
|
-
|
1461
|
-
new_name = f'py_xg_商品排行_万里马官方旗舰店_{date_all}.csv'
|
1462
|
-
# print(os.path.join(new_path, new_name))
|
1463
|
-
# breakpoint()
|
1464
|
-
df.to_csv(os.path.join(new_path, new_name), encoding='utf-8_sig', index=False, header=True)
|
1465
|
-
# try:
|
1466
|
-
# df.to_excel(os.path.join(new_path, new_name),
|
1467
|
-
# index=False, header=True, engine='openpyxl', freeze_panes=(1, 0))
|
1468
|
-
# except Exception as e:
|
1469
|
-
# print(e)
|
1470
|
-
|
1471
|
-
|
1472
|
-
|
1473
|
-
|
1474
1504
|
if __name__ == '__main__':
|
1475
1505
|
main(
|
1476
1506
|
service_databases = [
|
@@ -1479,7 +1509,7 @@ if __name__ == '__main__':
|
|
1479
1509
|
# {'home_lx': 'mongodb'},
|
1480
1510
|
# {'nas': 'mysql'},
|
1481
1511
|
],
|
1482
|
-
is_mysql = False,
|
1512
|
+
is_mysql = False, # 清理聚合数据
|
1483
1513
|
)
|
1484
1514
|
|
1485
1515
|
# c = DataClean(
|
mdbq/dataframe/converter.py
CHANGED
@@ -47,7 +47,7 @@ class DataFrameConverter(object):
|
|
47
47
|
try:
|
48
48
|
# 百分比在某些数据库中不兼容, 转换百分比为小数, # 转百分比的列不能含有中文或特殊字符
|
49
49
|
df[col] = df[col].apply(
|
50
|
-
lambda x: float(float((str(x).rstrip("%"))) / 100) if re.findall(r'^\d+\.?\d
|
50
|
+
lambda x: float(float((str(x).rstrip("%"))) / 100) if re.findall(r'^\d+\.?\d*%$', str(x)) else x)
|
51
51
|
except Exception as e:
|
52
52
|
print(f'留意错误信息: 位于列 -> {col} -> {e}')
|
53
53
|
|
@@ -94,5 +94,5 @@ if __name__ == '__main__':
|
|
94
94
|
# print(df['a'].dtype)
|
95
95
|
# print(df)
|
96
96
|
pattern = '1540%'
|
97
|
-
pattern = re.findall(r'^\d+\.?\d
|
97
|
+
pattern = re.findall(r'^\d+\.?\d*%$', pattern)
|
98
98
|
print(pattern)
|
@@ -1,15 +1,15 @@
|
|
1
1
|
mdbq/__init__.py,sha256=Il5Q9ATdX8yXqVxtP_nYqUhExzxPC_qk_WXQ_4h0exg,16
|
2
2
|
mdbq/__version__.py,sha256=y9Mp_8x0BCZSHsdLT_q5tX9wZwd5QgqrSIENLrb6vXA,62
|
3
3
|
mdbq/aggregation/__init__.py,sha256=EeDqX2Aml6SPx8363J-v1lz0EcZtgwIBYyCJV6CcEDU,40
|
4
|
-
mdbq/aggregation/aggregation.py,sha256
|
4
|
+
mdbq/aggregation/aggregation.py,sha256=-iXQ2XWVbVRJT3ek3VEoqPqepx0Npt0GW4m76jg82R0,76245
|
5
5
|
mdbq/aggregation/df_types.py,sha256=U9i3q2eRPTDY8qAPTw7irzu-Tlg4CIySW9uYro81wdk,8125
|
6
6
|
mdbq/aggregation/mysql_types.py,sha256=DQYROALDiwjJzjhaJfIIdnsrNs11i5BORlj_v6bp67Y,11062
|
7
7
|
mdbq/aggregation/optimize_data.py,sha256=gdScrgTAb6RbXHZy1LitX7lggMGn1GTLhkYSgztfwew,4903
|
8
|
-
mdbq/aggregation/query_data.py,sha256=
|
8
|
+
mdbq/aggregation/query_data.py,sha256=vSSXOKE2pUgadUoIcBfUPWOC1dc11vmxLOMtux4aPwI,102942
|
9
9
|
mdbq/bdup/__init__.py,sha256=AkhsGk81SkG1c8FqDH5tRq-8MZmFobVbN60DTyukYTY,28
|
10
10
|
mdbq/bdup/bdup.py,sha256=LAV0TgnQpc-LB-YuJthxb0U42_VkPidzQzAagan46lU,4234
|
11
11
|
mdbq/clean/__init__.py,sha256=A1d6x3L27j4NtLgiFV5TANwEkLuaDfPHDQNrPBbNWtU,41
|
12
|
-
mdbq/clean/clean_upload.py,sha256=
|
12
|
+
mdbq/clean/clean_upload.py,sha256=o151jxkRy8iEjWZ3df3tSB79y69QetHn9vz5zzq1zbM,78396
|
13
13
|
mdbq/clean/data_clean.py,sha256=ucfslhqXVZoH2QaXHSAWDky0GhIvH9f4GeNaHg4SrFE,104790
|
14
14
|
mdbq/company/__init__.py,sha256=qz8F_GsP_pMB5PblgJAUAMjasuZbOEp3qQOCB39E8f0,21
|
15
15
|
mdbq/company/copysh.py,sha256=NvlXCBZBcO2GIT5nLRYYqhOyHWM1-1RE7DHvgbj6jmQ,19723
|
@@ -20,7 +20,7 @@ mdbq/config/products.py,sha256=hN9UMkM6j76HYMulTYdtr3mOhh9QdpvvrLH14a_mbFY,5980
|
|
20
20
|
mdbq/config/set_support.py,sha256=xkZCX6y9Bq1ppBpJAofld4B2YtchA7fl0eT3dx3CrSI,777
|
21
21
|
mdbq/config/update_conf.py,sha256=taL3ZqKgiVWwUrDFuaYhim9a72Hm4BHRhhDscJTziR8,4535
|
22
22
|
mdbq/dataframe/__init__.py,sha256=2HtCN8AdRj53teXDqzysC1h8aPL-mMFy561ESmhehGQ,22
|
23
|
-
mdbq/dataframe/converter.py,sha256=
|
23
|
+
mdbq/dataframe/converter.py,sha256=KNHxk3dNw1ycOpcnTg83yHrV9B3pvoYwK3Wc_bzk2NE,4314
|
24
24
|
mdbq/log/__init__.py,sha256=Mpbrav0s0ifLL7lVDAuePEi1hJKiSHhxcv1byBKDl5E,15
|
25
25
|
mdbq/log/mylogger.py,sha256=oaT7Bp-Hb9jZt52seP3ISUuxVcI19s4UiqTeouScBO0,3258
|
26
26
|
mdbq/mongo/__init__.py,sha256=SILt7xMtQIQl_m-ik9WLtJSXIVf424iYgCfE_tnQFbw,13
|
@@ -42,7 +42,7 @@ mdbq/req_post/__init__.py,sha256=jso1oHcy6cJEfa7udS_9uO5X6kZLoPBF8l3wCYmr5dM,18
|
|
42
42
|
mdbq/req_post/req_tb.py,sha256=PexWSCPJNM6Tv0ol4lAWIhlOwsAr_frnjtcdSHCFiek,36179
|
43
43
|
mdbq/spider/__init__.py,sha256=RBMFXGy_jd1HXZhngB2T2XTvJqki8P_Fr-pBcwijnew,18
|
44
44
|
mdbq/spider/aikucun.py,sha256=3EjeTPbwk_qLGMVqDhBZoEPGfD2oM-SBiODjxLL3A8U,16883
|
45
|
-
mdbq-2.6.
|
46
|
-
mdbq-2.6.
|
47
|
-
mdbq-2.6.
|
48
|
-
mdbq-2.6.
|
45
|
+
mdbq-2.6.3.dist-info/METADATA,sha256=O3Xs0KdYzXEJ2LapxiFlxqnc1Q4fB3ujJ47O-QdF-iQ,245
|
46
|
+
mdbq-2.6.3.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
|
47
|
+
mdbq-2.6.3.dist-info/top_level.txt,sha256=2FQ-uLnCSB-OwFiWntzmwosW3X2Xqsg0ewh1axsaylA,5
|
48
|
+
mdbq-2.6.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|