ellipsis 3.1.46__py3-none-any.whl → 3.1.47__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.
Potentially problematic release.
This version of ellipsis might be problematic. Click here for more details.
- ellipsis/__init__.py +1 -1
- ellipsis/path/__init__.py +1 -0
- ellipsis/path/file/root.py +11 -4
- ellipsis/path/root.py +3 -15
- ellipsis/path/setUpTask/__init__.py +2 -0
- ellipsis/path/setUpTask/root.py +50 -0
- ellipsis/path/vector/timestamp/feature/series/root.py +3 -3
- {ellipsis-3.1.46.dist-info → ellipsis-3.1.47.dist-info}/METADATA +1 -1
- {ellipsis-3.1.46.dist-info → ellipsis-3.1.47.dist-info}/RECORD +12 -10
- {ellipsis-3.1.46.dist-info → ellipsis-3.1.47.dist-info}/LICENSE +0 -0
- {ellipsis-3.1.46.dist-info → ellipsis-3.1.47.dist-info}/WHEEL +0 -0
- {ellipsis-3.1.46.dist-info → ellipsis-3.1.47.dist-info}/top_level.txt +0 -0
ellipsis/__init__.py
CHANGED
ellipsis/path/__init__.py
CHANGED
ellipsis/path/file/root.py
CHANGED
|
@@ -8,20 +8,27 @@ import json
|
|
|
8
8
|
import pandas as pd
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
def add( filePath,
|
|
11
|
+
def add( token, filePath=None, memFile=None, parentId = None, publicAccess =None, metadata=None,name=None):
|
|
12
12
|
token = sanitize.validString('token', token, True)
|
|
13
13
|
parentId = sanitize.validUuid('parentId', parentId, False)
|
|
14
14
|
publicAccess = sanitize.validObject('publicAccess', publicAccess, False)
|
|
15
15
|
metadata = sanitize.validObject('metadata', metadata, False)
|
|
16
|
+
filePath = sanitize.validString('filePath', filePath, False)
|
|
17
|
+
name = sanitize.validString('name', name, False)
|
|
18
|
+
if type(memFile) == type(None) and type(filePath) == type(None):
|
|
19
|
+
raise ValueError('You need to specify either a filePath or a memFile')
|
|
20
|
+
if type(memFile) != type(None) and type(name) == type(None):
|
|
21
|
+
raise ValueError('Parameter name is required when using a memory file')
|
|
16
22
|
|
|
17
|
-
|
|
18
|
-
|
|
19
23
|
seperator = os.path.sep
|
|
20
24
|
fileName = filePath.split(seperator)[len(filePath.split(seperator))-1 ]
|
|
21
25
|
|
|
22
26
|
body = {'name':fileName, 'publicAccess':publicAccess, 'metadata':metadata, 'parentId':parentId}
|
|
27
|
+
if type(memFile) == type(None):
|
|
28
|
+
r = apiManager.upload('/path/file' , filePath, body, token, key = 'data')
|
|
29
|
+
else:
|
|
30
|
+
r = apiManager.upload('/path/file' , filePath , name, body, token, memfile = memFile)
|
|
23
31
|
|
|
24
|
-
r = apiManager.upload('/path/file' , filePath, body, token, key = 'data')
|
|
25
32
|
return r
|
|
26
33
|
|
|
27
34
|
|
ellipsis/path/root.py
CHANGED
|
@@ -155,24 +155,12 @@ def recover(pathId, token):
|
|
|
155
155
|
}, token)
|
|
156
156
|
|
|
157
157
|
|
|
158
|
-
def delete(pathId, token
|
|
158
|
+
def delete(pathId, token):
|
|
159
159
|
pathId = sanitize.validUuid('pathId', pathId, True)
|
|
160
160
|
token = sanitize.validString('token', token, False)
|
|
161
|
-
recursive = sanitize.validBool('recursive', recursive, True)
|
|
162
161
|
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
if info['type'] == 'folder':
|
|
166
|
-
folders = listFolder(pathId = pathId, includeTrashed=True, pathTypes=['folder'], token=token)['result']
|
|
167
|
-
for f in folders:
|
|
168
|
-
delete(f['id'], token, True)
|
|
169
|
-
maps = listFolder(pathId=pathId, pathTypes=['raster','vector','file', 'pointCloud'], includeTrashed=True, token=token)['result']
|
|
170
|
-
for m in maps:
|
|
171
|
-
delete(m['id'], token, True)
|
|
172
|
-
apiManager.delete(f'/path/{pathId}', None, token)
|
|
173
|
-
|
|
174
|
-
else:
|
|
175
|
-
return apiManager.delete(f'/path/{pathId}', None, token)
|
|
162
|
+
|
|
163
|
+
return apiManager.delete(f'/path/{pathId}', None, token)
|
|
176
164
|
|
|
177
165
|
def editPublicAccess(pathId, token, access = None, hidden=None, recursive = False):
|
|
178
166
|
pathId = sanitize.validUuid('pathId', pathId, True)
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
from ellipsis import apiManager
|
|
2
|
+
from ellipsis import sanitize
|
|
3
|
+
import os
|
|
4
|
+
|
|
5
|
+
def get(token):
|
|
6
|
+
token = sanitize.validString('token', token, False)
|
|
7
|
+
|
|
8
|
+
r = apiManager.get('/path/setUpTask', {}, token)
|
|
9
|
+
|
|
10
|
+
return r
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
def copernicusImport( parameters, token):
|
|
14
|
+
token = sanitize.validString('token', token, True)
|
|
15
|
+
parameters = sanitize.validObject('parameters', parameters, True)
|
|
16
|
+
r = apiManager.post('/path/setUpTask', {'type':'copernicusImport', 'parameters':parameters}, token)
|
|
17
|
+
|
|
18
|
+
return r
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def fileImport( token, memFile=None, parentId = None, filePath=None, fileFormat = 'geopackage', name = None):
|
|
22
|
+
token = sanitize.validString('token', token, True)
|
|
23
|
+
parentId = sanitize.validUuid(('parentId', parentId, False))
|
|
24
|
+
filePath = sanitize.validString('filePath', filePath, False)
|
|
25
|
+
name = sanitize.validString('name', name, False)
|
|
26
|
+
fileFormat = sanitize.validString('fileFormat', fileFormat, True)
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
if type(memFile) == type(None) and type(filePath) == type(None):
|
|
30
|
+
raise ValueError('You need to specify either a filePath or a memFile')
|
|
31
|
+
if type(memFile) != type(None) and type(name) == type(None):
|
|
32
|
+
raise ValueError('Parameter name is required when using a memory file')
|
|
33
|
+
|
|
34
|
+
if type(name) != type(None):
|
|
35
|
+
nameToUse = name
|
|
36
|
+
else:
|
|
37
|
+
seperator = os.path.sep
|
|
38
|
+
nameToUse = filePath.split(seperator)[len(filePath.split(seperator)) - 1]
|
|
39
|
+
|
|
40
|
+
parameters = {'name': nameToUse, 'parentId': parentId}
|
|
41
|
+
body = {'type': fileFormat + 'Import', 'parameters': parameters}
|
|
42
|
+
if type(memFile) == type(None):
|
|
43
|
+
r = apiManager.post('/path/setUpTask', body, token)
|
|
44
|
+
else:
|
|
45
|
+
r = apiManager.upload('/path/setUpTask' , filePath , name, body, token, memfile = memFile)
|
|
46
|
+
return r
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
|
|
@@ -82,17 +82,17 @@ def add(pathId, timestampId, seriesData, token, featureId=None, showProgress = T
|
|
|
82
82
|
df_sub['value'] = seriesData[c].astype(float)
|
|
83
83
|
dfs_long = dfs_long + [df_sub]
|
|
84
84
|
seriesData_long = pd.concat(dfs_long)
|
|
85
|
-
|
|
86
85
|
if uploadAsFile:
|
|
87
86
|
|
|
88
87
|
memfile = BytesIO()
|
|
89
|
-
seriesData_long.to_csv(memfile)
|
|
88
|
+
seriesData_long.to_csv(memfile, na_rep='null')
|
|
90
89
|
|
|
91
90
|
res = apiManager.upload(url = '/path/' + pathId + '/vector/timestamp/' + timestampId + '/feature/series', filePath = 'upload', body= {'name':'upload'}, token = token, key = 'data', memfile= memfile)
|
|
92
91
|
return res
|
|
93
92
|
else:
|
|
94
|
-
|
|
93
|
+
seriesData_long = seriesData_long.replace({float('nan'): None})
|
|
95
94
|
|
|
95
|
+
values = seriesData_long.to_dict('records')
|
|
96
96
|
|
|
97
97
|
chunks_values = chunks(values)
|
|
98
98
|
N = 0
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
ellipsis/__init__.py,sha256=
|
|
1
|
+
ellipsis/__init__.py,sha256=vkB0vbq2jydnn3Y_bh4qUAoUaF9Mb5yCuGVXdR6vsq4,210
|
|
2
2
|
ellipsis/apiManager.py,sha256=JJ-1nT29BIcVSzMvEdkm1Wq6PsXT7Jq5OmJrRdg7C2o,5463
|
|
3
3
|
ellipsis/sanitize.py,sha256=T5FawJRZ2eqGv0itiMkZ1fuJpahsSyhBMFty9cG-wwA,10194
|
|
4
4
|
ellipsis/account/__init__.py,sha256=K40DMBaUDSxt3rO2WZv63Wmpfy49ocqBxvWqyIYHR24,92
|
|
5
5
|
ellipsis/account/root.py,sha256=tgGAT2BzP3zgAqsevvkeognn5S67T-MrIP52BLN9rbE,1791
|
|
6
6
|
ellipsis/account/accessToken/__init__.py,sha256=ivwhK1eC4g74PAKaeTReb1QhIpKXyvmfdqZV6wDY-EY,66
|
|
7
7
|
ellipsis/account/accessToken/root.py,sha256=TYo8wTyWyzytaqOTsuQC-Vn3y7BhYMC88EItZafpISA,1281
|
|
8
|
-
ellipsis/path/__init__.py,sha256=
|
|
9
|
-
ellipsis/path/root.py,sha256=
|
|
8
|
+
ellipsis/path/__init__.py,sha256=NzdcTpXpicdrBWLgsFP6WY7ARIBKUFnkwa5VuB1Qdpc,506
|
|
9
|
+
ellipsis/path/root.py,sha256=GqiYjAkdSchkQf1NzcSFZvBrmoQir7K2fqmZosqghFM,7953
|
|
10
10
|
ellipsis/path/bookmark/__init__.py,sha256=vNrqGcWl5MN_xVAiClP6W6NilmsV-fqYOnJukbYcNwc,56
|
|
11
11
|
ellipsis/path/bookmark/root.py,sha256=knhVIVAJS0jBT6JLdVgnufVRdxIR0VZBYfv292hg6xY,1285
|
|
12
12
|
ellipsis/path/file/__init__.py,sha256=i_KB1S1J9pZjcPTKdyGMnjJf2tCoHFzptLGaxmTi55A,107
|
|
13
|
-
ellipsis/path/file/root.py,sha256=
|
|
13
|
+
ellipsis/path/file/root.py,sha256=zY7Hc5hRZkSvRsHnjfYwTTBBLcg9sYhbuqvXP_yWjxk,4993
|
|
14
14
|
ellipsis/path/folder/__init__.py,sha256=5keiFbsuXj5bYQHt8NahGkUYvXrJk8C7cQhgHA-4VBc,139
|
|
15
15
|
ellipsis/path/folder/root.py,sha256=OJSaOLWPQDXXty5sxsG_G0Fiip0VdWzj_XrcxY9Gnj8,1913
|
|
16
16
|
ellipsis/path/hashtag/__init__.py,sha256=4u8VC7xOFJjuZ9K08yh6GsPn8YkYZ_24o_7viScUQlg,59
|
|
@@ -39,6 +39,8 @@ ellipsis/path/raster/timestamp/file/__init__.py,sha256=Ln9_dQ4-PMwb5VP--Qh09IV5z
|
|
|
39
39
|
ellipsis/path/raster/timestamp/file/root.py,sha256=KD8E64eZtS62C-WCl3BTeVjsc08BaLXpuLwxfbmnTLI,4545
|
|
40
40
|
ellipsis/path/raster/timestamp/order/__init__.py,sha256=4YEK4XW9TM-HsjoFlFeyGMtI3OKX2VCXfb4NsTsugBo,74
|
|
41
41
|
ellipsis/path/raster/timestamp/order/root.py,sha256=zWcfI_q9KlfevzyvwWY8ni27KCvOyAiaJvohVfasjXg,1176
|
|
42
|
+
ellipsis/path/setUpTask/__init__.py,sha256=oDyCMCPzSIlMfAFIXrkviBlYwbPOmsUa3B3beyXfm_o,76
|
|
43
|
+
ellipsis/path/setUpTask/root.py,sha256=ERmbcGvxyCcGSKeJDe3bdYke9Do4VK02o-aeTQ77swM,1766
|
|
42
44
|
ellipsis/path/usage/__init__.py,sha256=2BHmLV9soOYDhyQFH2B86bBjmWXGsfuX4KneEBDo6O4,96
|
|
43
45
|
ellipsis/path/usage/root.py,sha256=NAZCDHXHcN6kodU3EpbNwlWM3It60ewsGXt4LJ_enG0,1566
|
|
44
46
|
ellipsis/path/vector/__init__.py,sha256=hIbJlp1kO_k2AhaFagUfd_We7taOBdD3K9n6lheWpYI,228
|
|
@@ -54,7 +56,7 @@ ellipsis/path/vector/timestamp/feature/root.py,sha256=Y_GiT1vBEvZxxvJdUvzhjGqYsf
|
|
|
54
56
|
ellipsis/path/vector/timestamp/feature/message/__init__.py,sha256=XfX3MIa4RjpToFnxNyfxCKTvRlNtJFRQ44j31wDyhGc,100
|
|
55
57
|
ellipsis/path/vector/timestamp/feature/message/root.py,sha256=isLzkITTiluKoIsH0PYT0K5Cr-LBzTA0TSE4-2tZU5M,3949
|
|
56
58
|
ellipsis/path/vector/timestamp/feature/series/__init__.py,sha256=vPi57QdUPTEnQE31abgxzwWU3Gzu-Xxi3ZVD4z5MMwg,107
|
|
57
|
-
ellipsis/path/vector/timestamp/feature/series/root.py,sha256=
|
|
59
|
+
ellipsis/path/vector/timestamp/feature/series/root.py,sha256=DEeX5noIHMQA-sNlyLnxiZEBBEs5Xpsnclv9Xfe6Uas,7605
|
|
58
60
|
ellipsis/path/vector/timestamp/file/__init__.py,sha256=qJtOXI9MEv4KifDjMW3zUDKnef8PD69SQmgRc3wDShQ,73
|
|
59
61
|
ellipsis/path/vector/timestamp/file/root.py,sha256=STswXCVZMtLmYceXKQsLKhyNmWzifDHp084mdS9fYLQ,4736
|
|
60
62
|
ellipsis/path/vector/timestamp/order/__init__.py,sha256=w11nMYDQJzZJU_q8o7ApadV2EOdCX93gNkHZ7PO1gUo,74
|
|
@@ -63,8 +65,8 @@ ellipsis/user/__init__.py,sha256=um_b42pc2otFiQRGqMajcEtONQpC2ei4r-EY3j7bsfQ,43
|
|
|
63
65
|
ellipsis/user/root.py,sha256=dsMK6wGBdeCmOd3YsbIv9cEcQ6tAiSGr0jmtBhQl5-0,484
|
|
64
66
|
ellipsis/util/__init__.py,sha256=_sNBUXDKJVGffRyt93xdUrJ4gON651Sp-unr7LKVCEc,756
|
|
65
67
|
ellipsis/util/root.py,sha256=Ts7DeaD_X7x-csmq5V2sa_hYrt1mCd59T7-NUQcWj3Y,23980
|
|
66
|
-
ellipsis-3.1.
|
|
67
|
-
ellipsis-3.1.
|
|
68
|
-
ellipsis-3.1.
|
|
69
|
-
ellipsis-3.1.
|
|
70
|
-
ellipsis-3.1.
|
|
68
|
+
ellipsis-3.1.47.dist-info/LICENSE,sha256=7EI8xVBu6h_7_JlVw-yPhhOZlpY9hP8wal7kHtqKT_E,1074
|
|
69
|
+
ellipsis-3.1.47.dist-info/METADATA,sha256=Qc1vooJjV5xuKr1Pwqi6SrDiZt5Dz55sAr7x1fx_dcc,1823
|
|
70
|
+
ellipsis-3.1.47.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
|
71
|
+
ellipsis-3.1.47.dist-info/top_level.txt,sha256=eG8gfaVDyprKdb-dsGSh_lFMSa3DiZCsJFqze239RjA,9
|
|
72
|
+
ellipsis-3.1.47.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|