junshan-kit 1.1.5__py2.py3-none-any.whl → 1.2.1__py2.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.
junshan_kit/kaggle_hub.py
CHANGED
@@ -3,20 +3,6 @@ import os
|
|
3
3
|
import shutil
|
4
4
|
from kaggle.api.kaggle_api_extended import KaggleApi
|
5
5
|
|
6
|
-
def read_data(data_name = 'evpd-test', copy_path = None):
|
7
|
-
path = kagglehub.dataset_download(f'junshan888/{data_name}')
|
8
|
-
# print("Downloaded to:", path)
|
9
|
-
if copy_path is not None:
|
10
|
-
# Create target directory if it doesn't exist
|
11
|
-
os.makedirs(copy_path, exist_ok=True)
|
12
|
-
# Copy dataset to target directory
|
13
|
-
shutil.copytree(path, copy_path, dirs_exist_ok=True)
|
14
|
-
|
15
|
-
print(f"✅ Dataset has been copied to: {copy_path}/{data_name}")
|
16
|
-
|
17
|
-
# example: read_data(copy_path='./exp_data')
|
18
|
-
|
19
|
-
|
20
6
|
def list_user_datasets():
|
21
7
|
api = KaggleApi()
|
22
8
|
api.authenticate()
|
@@ -33,3 +19,19 @@ def list_user_datasets():
|
|
33
19
|
print('*' * 60)
|
34
20
|
|
35
21
|
# example: list_user_datasets()
|
22
|
+
|
23
|
+
#---------------------------------------------------------------
|
24
|
+
def read_data(data_name = 'evpd-test', copy_path = None):
|
25
|
+
path = kagglehub.dataset_download(f'junshan888/{data_name}')
|
26
|
+
# print("Downloaded to:", path)
|
27
|
+
if copy_path is not None:
|
28
|
+
# Create target directory if it doesn't exist
|
29
|
+
os.makedirs(copy_path, exist_ok=True)
|
30
|
+
# Copy dataset to target directory
|
31
|
+
shutil.copytree(path, copy_path, dirs_exist_ok=True)
|
32
|
+
|
33
|
+
print(f"✅ Dataset has been copied to: {copy_path}/{data_name}")
|
34
|
+
|
35
|
+
# example: read_data(copy_path='./exp_data')
|
36
|
+
|
37
|
+
|
@@ -0,0 +1,5 @@
|
|
1
|
+
junshan_kit/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
+
junshan_kit/kaggle_hub.py,sha256=2YRHu8Zf6gphMUosi5njoGgIjNntk8hoCKQPmcNUfho,1092
|
3
|
+
junshan_kit-1.2.1.dist-info/METADATA,sha256=Fqpe4V10OILJb2DzEBd-EMiJIseVSpGxj2C64nAuVNk,303
|
4
|
+
junshan_kit-1.2.1.dist-info/WHEEL,sha256=tkmg4JIqwd9H8mL30xA7crRmoStyCtGp0VWshokd1Jc,105
|
5
|
+
junshan_kit-1.2.1.dist-info/RECORD,,
|
@@ -1,5 +0,0 @@
|
|
1
|
-
junshan_kit/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
-
junshan_kit/kaggle_hub.py,sha256=wUQGHx69w64eMC4CsTEhfmyhpBSUyXmN9kfDaM_sRes,1026
|
3
|
-
junshan_kit-1.1.5.dist-info/METADATA,sha256=6X3IDb8MytIdgJ1HfEgTPUvJ0fu_yk9GJgW00XbLF88,303
|
4
|
-
junshan_kit-1.1.5.dist-info/WHEEL,sha256=tkmg4JIqwd9H8mL30xA7crRmoStyCtGp0VWshokd1Jc,105
|
5
|
-
junshan_kit-1.1.5.dist-info/RECORD,,
|
File without changes
|