oafuncs 0.0.73__tar.gz → 0.0.75__tar.gz
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.
- oafuncs-0.0.75/MANIFEST.in +1 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/PKG-INFO +1 -1
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_down/hycom_3hourly.py +19 -78
- oafuncs-0.0.75/oafuncs/oa_down/test.py +104 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs.egg-info/PKG-INFO +1 -1
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs.egg-info/SOURCES.txt +2 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/setup.py +1 -1
- {oafuncs-0.0.73 → oafuncs-0.0.75}/LICENSE.txt +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/README.md +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/__init__.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_cmap.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_data.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_down/__init__.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_down/literature.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_down/refs_pdf.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_draw.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_file.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_help.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_nc.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_python.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_sign/__init__.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_sign/meteorological.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_sign/ocean.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_sign/scientific.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_tool/__init__.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs/oa_tool/email.py +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs.egg-info/dependency_links.txt +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs.egg-info/requires.txt +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/oafuncs.egg-info/top_level.txt +0 -0
- {oafuncs-0.0.73 → oafuncs-0.0.75}/setup.cfg +0 -0
@@ -0,0 +1 @@
|
|
1
|
+
include oa_down/User_Agent-list.txt
|
@@ -4,7 +4,7 @@
|
|
4
4
|
Author: Liu Kun && 16031215@qq.com
|
5
5
|
Date: 2024-11-01 10:31:09
|
6
6
|
LastEditors: Liu Kun && 16031215@qq.com
|
7
|
-
LastEditTime: 2024-12-01
|
7
|
+
LastEditTime: 2024-12-01 19:10:10
|
8
8
|
FilePath: \\Python\\My_Funcs\\OAFuncs\\oafuncs\\oa_down\\hycom_3hourly.py
|
9
9
|
Description:
|
10
10
|
EditPlatform: vscode
|
@@ -29,7 +29,7 @@ from rich.progress import Progress
|
|
29
29
|
|
30
30
|
warnings.filterwarnings("ignore", category=RuntimeWarning, message="Engine '.*' loading failed:.*")
|
31
31
|
|
32
|
-
__all__ = ['draw_time_range', 'download', 'how_to_use', 'get_time_list']
|
32
|
+
__all__ = ['draw_time_range', 'download', 'how_to_use', 'get_time_list', 'get_ua']
|
33
33
|
|
34
34
|
# time resolution
|
35
35
|
data_info = {'yearly': {}, 'monthly': {}, 'daily': {}, 'hourly': {}}
|
@@ -504,75 +504,16 @@ def check_existing_file(file_full_path):
|
|
504
504
|
|
505
505
|
|
506
506
|
def get_ua():
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv,2.0.1) Gecko/20100101 Firefox/4.0.1",
|
518
|
-
"Mozilla/5.0 (Windows NT 6.1; rv,2.0.1) Gecko/20100101 Firefox/4.0.1",
|
519
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/534.57.2 (KHTML, like Gecko) Version/5.1.7 Safari/534.57.2",
|
520
|
-
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.122 Safari/537.36",
|
521
|
-
"Mozilla/5.0 (Windows; U; Windows NT 6.1; en-us) AppleWebKit/534.50 (KHTML, like Gecko) Version/5.1 Safari/534.50",
|
522
|
-
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
523
|
-
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
524
|
-
"Mozilla/5.0 (iPad; U; CPU OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
525
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36",
|
526
|
-
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11",
|
527
|
-
"Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.133 Safari/534.16",
|
528
|
-
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_0) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11",
|
529
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.101 Safari/537.36",
|
530
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko",
|
531
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; 360SE)",
|
532
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.11 TaoBrowser/2.0 Safari/536.11",
|
533
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.71 Safari/537.1 LBBROWSER",
|
534
|
-
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; LBBROWSER)",
|
535
|
-
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; QQDownload 732; .NET4.0C; .NET4.0E; LBBROWSER)"
|
536
|
-
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; QQBrowser/7.0.3698.400)",
|
537
|
-
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; QQDownload 732; .NET4.0C; .NET4.0E)",
|
538
|
-
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.84 Safari/535.11 SE 2.X MetaSr 1.0",
|
539
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; SV1; QQDownload 732; .NET4.0C; .NET4.0E; SE 2.X MetaSr 1.0)",
|
540
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; SE 2.X MetaSr 1.0; SE 2.X MetaSr 1.0; .NET CLR 2.0.50727; SE 2.X MetaSr 1.0)",
|
541
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Maxthon/4.4.3.4000 Chrome/30.0.1599.101 Safari/537.36",
|
542
|
-
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_0) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11",
|
543
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.122 UBrowser/4.0.3214.0 Safari/537.36",
|
544
|
-
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 UBrowser/6.2.4094.1 Safari/537.36",
|
545
|
-
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
546
|
-
"Mozilla/5.0 (iPod; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
547
|
-
"Mozilla/5.0 (iPad; U; CPU OS 4_2_1 like Mac OS X; zh-cn) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8C148 Safari/6533.18.5",
|
548
|
-
"Mozilla/5.0 (iPad; U; CPU OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
549
|
-
"Mozilla/5.0 (Linux; U; Android 2.2.1; zh-cn; HTC_Wildfire_A3333 Build/FRG83D) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
550
|
-
"Mozilla/5.0 (Linux; U; Android 2.3.7; en-us; Nexus One Build/FRF91) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
551
|
-
"MQQBrowser/26 Mozilla/5.0 (Linux; U; Android 2.3.7; zh-cn; MB200 Build/GRJ22; CyanogenMod-7) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
552
|
-
"Opera/9.80 (Android 2.3.4; Linux; Opera Mobi/build-1107180945; U; en-GB) Presto/2.8.149 Version/11.10",
|
553
|
-
"Mozilla/5.0 (Linux; U; Android 3.0; en-us; Xoom Build/HRI39) AppleWebKit/534.13 (KHTML, like Gecko) Version/4.0 Safari/534.13",
|
554
|
-
"Mozilla/5.0 (BlackBerry; U; BlackBerry 9800; en) AppleWebKit/534.1+ (KHTML, like Gecko) Version/6.0.0.337 Mobile Safari/534.1+",
|
555
|
-
"Mozilla/5.0 (hp-tablet; Linux; hpwOS/3.0.0; U; en-US) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 TouchPad/1.0",
|
556
|
-
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0;",
|
557
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0)",
|
558
|
-
"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0)",
|
559
|
-
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)",
|
560
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)",
|
561
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; The World)",
|
562
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; TencentTraveler 4.0)",
|
563
|
-
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Avant Browser)",
|
564
|
-
"Mozilla/5.0 (Linux; U; Android 2.3.7; en-us; Nexus One Build/FRF91) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
565
|
-
"Mozilla/5.0 (SymbianOS/9.4; Series60/5.0 NokiaN97-1/20.0.019; Profile/MIDP-2.1 Configuration/CLDC-1.1) AppleWebKit/525 (KHTML, like Gecko) BrowserNG/7.1.18124",
|
566
|
-
"Mozilla/5.0 (compatible; MSIE 9.0; Windows Phone OS 7.5; Trident/5.0; IEMobile/9.0; HTC; Titan)",
|
567
|
-
"UCWEB7.0.2.37/28/999",
|
568
|
-
"NOKIA5700/UCWEB7.0.2.37/28/999",
|
569
|
-
"Openwave/UCWEB7.0.2.37/28/999",
|
570
|
-
"Openwave/UCWEB7.0.2.37/28/999",
|
571
|
-
|
572
|
-
]
|
573
|
-
# print(f'Using User-Agent: {ua}')
|
574
|
-
ua = random.choice(ua_list)
|
575
|
-
return ua
|
507
|
+
current_dir = os.path.dirname(os.path.abspath(__file__))
|
508
|
+
ua_file_txt = os.path.join(current_dir, 'User_Agent-list.txt')
|
509
|
+
|
510
|
+
with open(ua_file_txt, 'r') as f:
|
511
|
+
ua_list = f.readlines()
|
512
|
+
# 去掉换行符和空行
|
513
|
+
ua_list = [line.strip() for line in ua_list if line.strip()]
|
514
|
+
|
515
|
+
return random.choice(ua_list)
|
516
|
+
|
576
517
|
|
577
518
|
|
578
519
|
def get_proxy():
|
@@ -739,7 +680,7 @@ def get_submit_url_var(var, depth, level_num, lon_min, lon_max, lat_min, lat_max
|
|
739
680
|
|
740
681
|
|
741
682
|
def prepare_url_to_download(var, lon_min=0, lon_max=359.92, lat_min=-80, lat_max=90, download_time='2024083100', download_time_end=None, depth=None, level_num=None, store_path=None, dataset_name=None, version_name=None, check=False):
|
742
|
-
print('[bold #ecdbfe]-'*
|
683
|
+
print('[bold #ecdbfe]-'*160)
|
743
684
|
download_time = str(download_time)
|
744
685
|
if download_time_end is not None:
|
745
686
|
download_time_end = str(download_time_end)
|
@@ -859,14 +800,14 @@ def download_hourly_func(var, time_s, time_e, lon_min=0, lon_max=359.92, lat_min
|
|
859
800
|
if num_workers is None or num_workers <= 1:
|
860
801
|
# 串行方式
|
861
802
|
for i, time_str in enumerate(new_time_list):
|
862
|
-
time_str_end_index = int(min(len(time_list), int(i*ftimes+ftimes-1)))
|
803
|
+
time_str_end_index = int(min(len(time_list)-1, int(i*ftimes+ftimes-1)))
|
863
804
|
time_str_end = time_list[time_str_end_index]
|
864
805
|
prepare_url_to_download(var, lon_min, lon_max, lat_min, lat_max, time_str, time_str_end, depth, level, store_path, dataset_name, version_name, check)
|
865
806
|
progress.update(task, advance=1, description=f'[cyan]Downloading... {i+1}/{total_num}')
|
866
807
|
else:
|
867
808
|
# 并行方式
|
868
809
|
with ThreadPoolExecutor(max_workers=num_workers) as executor:
|
869
|
-
futures = [executor.submit(download_task, var, new_time_list[i], time_list[int(min(len(time_list), int(i*ftimes+ftimes-1)))], lon_min, lon_max, lat_min, lat_max, depth, level, store_path, dataset_name, version_name, check) for i in range(total_num)]
|
810
|
+
futures = [executor.submit(download_task, var, new_time_list[i], time_list[int(min(len(time_list)-1, int(i*ftimes+ftimes-1)))], lon_min, lon_max, lat_min, lat_max, depth, level, store_path, dataset_name, version_name, check) for i in range(total_num)]
|
870
811
|
for i, future in enumerate(futures):
|
871
812
|
future.add_done_callback(lambda _: progress.update(task, advance=1, description=f'[cyan]Downloading... {i+1}/{total_num}'))
|
872
813
|
else:
|
@@ -1005,7 +946,7 @@ def how_to_use():
|
|
1005
946
|
|
1006
947
|
if __name__ == '__main__':
|
1007
948
|
# help(hycom3h.download)
|
1008
|
-
time_s, time_e = '
|
949
|
+
time_s, time_e = '2016070100', '2019123121'
|
1009
950
|
merge_name = '2018_2024'
|
1010
951
|
root_path = r'G:\Data\HYCOM\3hourly'
|
1011
952
|
location_dict = {'west': 105, 'east': 130, 'south': 15, 'north': 45}
|
@@ -1033,11 +974,11 @@ if __name__ == '__main__':
|
|
1033
974
|
num_workers = 1
|
1034
975
|
|
1035
976
|
check = True
|
1036
|
-
ftimes =
|
977
|
+
ftimes = 1
|
1037
978
|
|
1038
979
|
download_switch, single_var = True, False
|
1039
|
-
combine_switch =
|
1040
|
-
copy_switch, copy_dir =
|
980
|
+
combine_switch = False
|
981
|
+
copy_switch, copy_dir = False, r'G:\Data\HYCOM\3hourly'
|
1041
982
|
|
1042
983
|
if download_switch:
|
1043
984
|
if single_var:
|
@@ -0,0 +1,104 @@
|
|
1
|
+
#!/usr/bin/env python
|
2
|
+
# coding=utf-8
|
3
|
+
'''
|
4
|
+
Author: Liu Kun && 16031215@qq.com
|
5
|
+
Date: 2024-12-01 19:32:25
|
6
|
+
LastEditors: Liu Kun && 16031215@qq.com
|
7
|
+
LastEditTime: 2024-12-01 19:38:40
|
8
|
+
FilePath: \\Python\\My_Funcs\\OAFuncs\\oafuncs\\oa_down\\test.py
|
9
|
+
Description:
|
10
|
+
EditPlatform: vscode
|
11
|
+
ComputerInfo: XPS 15 9510
|
12
|
+
SystemInfo: Windows 11
|
13
|
+
Python Version: 3.12
|
14
|
+
'''
|
15
|
+
|
16
|
+
import os
|
17
|
+
import random
|
18
|
+
|
19
|
+
|
20
|
+
def get_ua():
|
21
|
+
current_dir = os.path.dirname(os.path.abspath(__file__))
|
22
|
+
ua_file_txt = os.path.join(current_dir, 'User_Agent-list.txt')
|
23
|
+
|
24
|
+
with open(ua_file_txt, 'r') as f:
|
25
|
+
ua_list = f.readlines()
|
26
|
+
# 去掉换行符和空行
|
27
|
+
ua_list = [line.strip() for line in ua_list if line.strip()]
|
28
|
+
|
29
|
+
return random.choice(ua_list)
|
30
|
+
|
31
|
+
|
32
|
+
print(get_ua())
|
33
|
+
|
34
|
+
|
35
|
+
def get_ua_org():
|
36
|
+
ua_list = [
|
37
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.95 Safari/537.36 OPR/26.0.1656.60",
|
38
|
+
"Opera/8.0 (Windows NT 5.1; U; en)",
|
39
|
+
"Mozilla/5.0 (Windows NT 5.1; U; en; rv:1.8.1) Gecko/20061208 Firefox/2.0.0 Opera 9.50",
|
40
|
+
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; en) Opera 9.50",
|
41
|
+
"Opera/9.80 (Macintosh; Intel Mac OS X 10.6.8; U; en) Presto/2.8.131 Version/11.11",
|
42
|
+
"Opera/9.80 (Windows NT 6.1; U; en) Presto/2.8.131 Version/11.11",
|
43
|
+
"Opera/9.80 (Android 2.3.4; Linux; Opera Mobi/build-1107180945; U; en-GB) Presto/2.8.149 Version/11.10",
|
44
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:34.0) Gecko/20100101 Firefox/34.0",
|
45
|
+
"Mozilla/5.0 (X11; U; Linux x86_64; zh-CN; rv:1.9.2.10) Gecko/20100922 Ubuntu/10.10 (maverick) Firefox/3.6.10",
|
46
|
+
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv,2.0.1) Gecko/20100101 Firefox/4.0.1",
|
47
|
+
"Mozilla/5.0 (Windows NT 6.1; rv,2.0.1) Gecko/20100101 Firefox/4.0.1",
|
48
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/534.57.2 (KHTML, like Gecko) Version/5.1.7 Safari/534.57.2",
|
49
|
+
"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.122 Safari/537.36",
|
50
|
+
"Mozilla/5.0 (Windows; U; Windows NT 6.1; en-us) AppleWebKit/534.50 (KHTML, like Gecko) Version/5.1 Safari/534.50",
|
51
|
+
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
52
|
+
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
53
|
+
"Mozilla/5.0 (iPad; U; CPU OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
54
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36",
|
55
|
+
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11",
|
56
|
+
"Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.133 Safari/534.16",
|
57
|
+
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_0) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11",
|
58
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.101 Safari/537.36",
|
59
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko",
|
60
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; 360SE)",
|
61
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.11 TaoBrowser/2.0 Safari/536.11",
|
62
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.71 Safari/537.1 LBBROWSER",
|
63
|
+
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; LBBROWSER)",
|
64
|
+
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; QQDownload 732; .NET4.0C; .NET4.0E; LBBROWSER)",
|
65
|
+
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; QQBrowser/7.0.3698.400)",
|
66
|
+
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; QQDownload 732; .NET4.0C; .NET4.0E)",
|
67
|
+
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.84 Safari/535.11 SE 2.X MetaSr 1.0",
|
68
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; SV1; QQDownload 732; .NET4.0C; .NET4.0E; SE 2.X MetaSr 1.0)",
|
69
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; SE 2.X MetaSr 1.0; SE 2.X MetaSr 1.0; .NET CLR 2.0.50727; SE 2.X MetaSr 1.0)",
|
70
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Maxthon/4.4.3.4000 Chrome/30.0.1599.101 Safari/537.36",
|
71
|
+
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_0) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11",
|
72
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.122 UBrowser/4.0.3214.0 Safari/537.36",
|
73
|
+
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 UBrowser/6.2.4094.1 Safari/537.36",
|
74
|
+
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
75
|
+
"Mozilla/5.0 (iPod; U; CPU iPhone OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
76
|
+
"Mozilla/5.0 (iPad; U; CPU OS 4_2_1 like Mac OS X; zh-cn) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8C148 Safari/6533.18.5",
|
77
|
+
"Mozilla/5.0 (iPad; U; CPU OS 4_3_3 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8J2 Safari/6533.18.5",
|
78
|
+
"Mozilla/5.0 (Linux; U; Android 2.2.1; zh-cn; HTC_Wildfire_A3333 Build/FRG83D) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
79
|
+
"Mozilla/5.0 (Linux; U; Android 2.3.7; en-us; Nexus One Build/FRF91) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
80
|
+
"MQQBrowser/26 Mozilla/5.0 (Linux; U; Android 2.3.7; zh-cn; MB200 Build/GRJ22; CyanogenMod-7) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
81
|
+
"Opera/9.80 (Android 2.3.4; Linux; Opera Mobi/build-1107180945; U; en-GB) Presto/2.8.149 Version/11.10",
|
82
|
+
"Mozilla/5.0 (Linux; U; Android 3.0; en-us; Xoom Build/HRI39) AppleWebKit/534.13 (KHTML, like Gecko) Version/4.0 Safari/534.13",
|
83
|
+
"Mozilla/5.0 (BlackBerry; U; BlackBerry 9800; en) AppleWebKit/534.1+ (KHTML, like Gecko) Version/6.0.0.337 Mobile Safari/534.1+",
|
84
|
+
"Mozilla/5.0 (hp-tablet; Linux; hpwOS/3.0.0; U; en-US) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 TouchPad/1.0",
|
85
|
+
"Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0;",
|
86
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0)",
|
87
|
+
"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0)",
|
88
|
+
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)",
|
89
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)",
|
90
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; The World)",
|
91
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; TencentTraveler 4.0)",
|
92
|
+
"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Avant Browser)",
|
93
|
+
"Mozilla/5.0 (Linux; U; Android 2.3.7; en-us; Nexus One Build/FRF91) AppleWebKit/533.1 (KHTML, like Gecko) Version/4.0 Mobile Safari/533.1",
|
94
|
+
"Mozilla/5.0 (SymbianOS/9.4; Series60/5.0 NokiaN97-1/20.0.019; Profile/MIDP-2.1 Configuration/CLDC-1.1) AppleWebKit/525 (KHTML, like Gecko) BrowserNG/7.1.18124",
|
95
|
+
"Mozilla/5.0 (compatible; MSIE 9.0; Windows Phone OS 7.5; Trident/5.0; IEMobile/9.0; HTC; Titan)",
|
96
|
+
"UCWEB7.0.2.37/28/999",
|
97
|
+
"NOKIA5700/UCWEB7.0.2.37/28/999",
|
98
|
+
"Openwave/UCWEB7.0.2.37/28/999",
|
99
|
+
"Openwave/UCWEB7.0.2.37/28/999",
|
100
|
+
|
101
|
+
]
|
102
|
+
# print(f'Using User-Agent: {ua}')
|
103
|
+
ua = random.choice(ua_list)
|
104
|
+
return ua
|
@@ -1,4 +1,5 @@
|
|
1
1
|
LICENSE.txt
|
2
|
+
MANIFEST.in
|
2
3
|
README.md
|
3
4
|
setup.py
|
4
5
|
oafuncs/__init__.py
|
@@ -18,6 +19,7 @@ oafuncs/oa_down/__init__.py
|
|
18
19
|
oafuncs/oa_down/hycom_3hourly.py
|
19
20
|
oafuncs/oa_down/literature.py
|
20
21
|
oafuncs/oa_down/refs_pdf.py
|
22
|
+
oafuncs/oa_down/test.py
|
21
23
|
oafuncs/oa_sign/__init__.py
|
22
24
|
oafuncs/oa_sign/meteorological.py
|
23
25
|
oafuncs/oa_sign/ocean.py
|
@@ -18,7 +18,7 @@ URL = 'https://github.com/Industry-Pays/OAFuncs'
|
|
18
18
|
EMAIL = 'liukun0312@stu.ouc.edu.cn'
|
19
19
|
AUTHOR = 'Kun Liu'
|
20
20
|
REQUIRES_PYTHON = '>=3.9.0'
|
21
|
-
VERSION = '0.0.
|
21
|
+
VERSION = '0.0.75'
|
22
22
|
|
23
23
|
# What packages are required for this module to be executed?
|
24
24
|
REQUIRED = [
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|