ellipsis 3.1.4__py3-none-any.whl → 3.1.6__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/raster/root.py +3 -2
- ellipsis/path/raster/timestamp/file/root.py +1 -1
- ellipsis/path/root.py +1 -1
- ellipsis/path/vector/timestamp/feature/root.py +4 -16
- ellipsis/path/vector/timestamp/root.py +2 -2
- ellipsis/sanitize.py +19 -0
- ellipsis/util/root.py +1 -1
- {ellipsis-3.1.4.dist-info → ellipsis-3.1.6.dist-info}/METADATA +1 -1
- {ellipsis-3.1.4.dist-info → ellipsis-3.1.6.dist-info}/RECORD +13 -13
- {ellipsis-3.1.4.dist-info → ellipsis-3.1.6.dist-info}/LICENSE +0 -0
- {ellipsis-3.1.4.dist-info → ellipsis-3.1.6.dist-info}/WHEEL +0 -0
- {ellipsis-3.1.4.dist-info → ellipsis-3.1.6.dist-info}/top_level.txt +0 -0
ellipsis/__init__.py
CHANGED
ellipsis/path/raster/root.py
CHANGED
|
@@ -24,14 +24,15 @@ def editBand(pathId, bandNumber, name, token):
|
|
|
24
24
|
return(r)
|
|
25
25
|
|
|
26
26
|
# /path/{pathId}/raster
|
|
27
|
-
def edit(pathId, token, interpolation = None, includesTransparent = None):
|
|
27
|
+
def edit(pathId, token, interpolation = None, includesTransparent = None, compressionQuality = None):
|
|
28
28
|
|
|
29
29
|
token = sanitize.validString('token', token, True)
|
|
30
30
|
pathId = sanitize.validUuid('pathId', pathId, True)
|
|
31
31
|
interpolation = sanitize.validString('interpolation', interpolation, False)
|
|
32
32
|
includesTransparent = sanitize.validBool('includesTransparent', includesTransparent, False)
|
|
33
|
+
compressionQuality = sanitize.validInt('compressionQuality', compressionQuality, False)
|
|
33
34
|
|
|
34
|
-
body = {'interpolation':interpolation, 'includesTransparent':includesTransparent}
|
|
35
|
+
body = {'interpolation':interpolation, 'includesTransparent':includesTransparent, 'compressionQuality':compressionQuality}
|
|
35
36
|
r = apiManager.patch('/path/' + pathId + '/raster' , body, token)
|
|
36
37
|
return(r)
|
|
37
38
|
|
|
@@ -29,7 +29,7 @@ def get(pathId, timestampId, token, pageStart= None, listAll = True):
|
|
|
29
29
|
pageStart = sanitize.validUuid('pageStart', pageStart, False)
|
|
30
30
|
|
|
31
31
|
def f(body):
|
|
32
|
-
r = apiManager.get('/path/' + pathId + '/raster/timestamp/' + timestampId + '/file',
|
|
32
|
+
r = apiManager.get('/path/' + pathId + '/raster/timestamp/' + timestampId + '/file', body, token)
|
|
33
33
|
for i in np.arange( len(r['result'])):
|
|
34
34
|
if 'info' in r['result'][i].keys() and 'bounds' in r['result'][i]['info'].keys() and type(r['result'][i]['info']['bounds']) != type(None):
|
|
35
35
|
r['result'][i]['info']['bounds'] = gpd.GeoDataFrame.from_features([{'id': 0, 'properties':{}, 'geometry':r['result'][i]['info']['bounds']}]).unary_union
|
ellipsis/path/root.py
CHANGED
|
@@ -26,7 +26,7 @@ def search(pathTypes = ['raster', 'vector', 'file', 'folder'] ,root=None, text=N
|
|
|
26
26
|
date = sanitize.validDateRange('date', date, False)
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
resolution = sanitize.
|
|
29
|
+
resolution = sanitize.validResolution('resolution', resolution, False)
|
|
30
30
|
|
|
31
31
|
body = {
|
|
32
32
|
'type': pathTypes,
|
|
@@ -76,12 +76,11 @@ def zipLevels(levelOfDetail1, levelOfDetail2, levelOfDetail3, levelOfDetail4, le
|
|
|
76
76
|
levels = None
|
|
77
77
|
return levels
|
|
78
78
|
|
|
79
|
-
def add(pathId, timestampId, features, token, showProgress = True,
|
|
79
|
+
def add(pathId, timestampId, features, token, showProgress = True, levelOfDetail1 = None, levelOfDetail2 = None, levelOfDetail3 = None, levelOfDetail4 = None, levelOfDetail5 = None, cores = 1):
|
|
80
80
|
pathId = sanitize.validUuid('pathId', pathId, True)
|
|
81
81
|
timestampId = sanitize.validUuid('timestampId', timestampId, True)
|
|
82
82
|
token = sanitize.validString('token', token, True)
|
|
83
83
|
features = sanitize.validGeopandas('features', features, True, cores = cores)
|
|
84
|
-
zoomLevels = sanitize.validIntArray('zoomLevels', zoomLevels, False)
|
|
85
84
|
showProgress = sanitize.validBool('showProgress', showProgress, True)
|
|
86
85
|
cores = sanitize.validInt('cores', cores, True)
|
|
87
86
|
|
|
@@ -127,9 +126,9 @@ def add(pathId, timestampId, features, token, showProgress = True, zoomLevels =
|
|
|
127
126
|
levels = zipLevels(levelOfDetail1, levelOfDetail2, levelOfDetail3, levelOfDetail4, levelOfDetail5, indices_sub)
|
|
128
127
|
|
|
129
128
|
if type(levels) != type(None):
|
|
130
|
-
featuresBody = [{'feature': features_sub[i], '
|
|
129
|
+
featuresBody = [{'feature': features_sub[i], 'levelsOfDetail': levels[i] } for i in np.arange(len(indices_sub))]
|
|
131
130
|
else:
|
|
132
|
-
featuresBody = [{'feature': features_sub[i]
|
|
131
|
+
featuresBody = [{'feature': features_sub[i] } for i in np.arange(len(indices_sub))]
|
|
133
132
|
body = {"features":featuresBody}
|
|
134
133
|
r = apiManager.post('/path/' + pathId + '/vector/timestamp/' + timestampId + '/feature', body, token)
|
|
135
134
|
addedIds = addedIds + r
|
|
@@ -141,12 +140,11 @@ def add(pathId, timestampId, features, token, showProgress = True, zoomLevels =
|
|
|
141
140
|
|
|
142
141
|
|
|
143
142
|
|
|
144
|
-
def edit(pathId, timestampId, featureIds, token, features = None, showProgress = True,
|
|
143
|
+
def edit(pathId, timestampId, featureIds, token, features = None, showProgress = True, levelOfDetail1 = None, levelOfDetail2 = None, levelOfDetail3 = None, levelOfDetail4 = None, levelOfDetail5 = None, cores = 1):
|
|
145
144
|
pathId = sanitize.validUuid('pathId', pathId, True)
|
|
146
145
|
timestampId = sanitize.validUuid('timestampId', timestampId, True)
|
|
147
146
|
token = sanitize.validString('token', token, True)
|
|
148
147
|
features = sanitize.validGeopandas('features', features, False, cores=cores)
|
|
149
|
-
newZoomLevels = sanitize.validIntArray('newZoomLevels', newZoomLevels, False)
|
|
150
148
|
featureIds = sanitize.validUuidArray('featureIds', featureIds, True)
|
|
151
149
|
showProgress = sanitize.validBool('showProgress', showProgress, True)
|
|
152
150
|
cores = sanitize.validInt('cores', cores, True)
|
|
@@ -172,18 +170,8 @@ def edit(pathId, timestampId, featureIds, token, features = None, showProgress =
|
|
|
172
170
|
levels = zipLevels(levelOfDetail1, levelOfDetail2, levelOfDetail3, levelOfDetail4, levelOfDetail5, indices_sub)
|
|
173
171
|
|
|
174
172
|
if type(levels) == type(None):
|
|
175
|
-
if str(type(newZoomLevels)) != str(type(None)) and str(type(features)) != str(type(None)):
|
|
176
|
-
changes = [{'featureId':x[0] , 'newProperties':x[1]['properties'], 'newGeometry':x[1]['geometry'], 'newZoomLevels':newZoomLevels} for x in zip(featureIds_sub, features_sub['features'])]
|
|
177
|
-
elif str(type(newZoomLevels)) != str(type(None)) and str(type(features)) == str(type(None)):
|
|
178
|
-
changes = [{'featureId':geometryId, 'newZoomLevels':newZoomLevels} for geometryId in featureIds]
|
|
179
|
-
else:
|
|
180
173
|
changes = [{'featureId':x[0] , 'newProperties':x[1]['properties'], 'newGeometry':x[1]['geometry']} for x in zip(featureIds_sub, features_sub['features'])]
|
|
181
174
|
else:
|
|
182
|
-
if str(type(newZoomLevels)) != str(type(None)) and str(type(features)) != str(type(None)):
|
|
183
|
-
changes = [{'featureId':x[0] , 'levelsOfDetail': levels , 'newProperties':x[1]['properties'], 'newGeometry':x[1]['geometry'], 'newZoomLevels':newZoomLevels} for x in zip(featureIds_sub, features_sub['features'])]
|
|
184
|
-
elif str(type(newZoomLevels)) != str(type(None)) and str(type(features)) == str(type(None)):
|
|
185
|
-
changes = [{'featureId':geometryId, 'levelsOfDetail': levels, 'newZoomLevels':newZoomLevels} for geometryId in featureIds]
|
|
186
|
-
else:
|
|
187
175
|
changes = [{'featureId':x[0], 'levelsOfDetail': levels , 'newProperties':x[1]['properties'], 'newGeometry':x[1]['geometry']} for x in zip(featureIds_sub, features_sub['features'])]
|
|
188
176
|
|
|
189
177
|
body = {'changes':changes}
|
|
@@ -146,7 +146,7 @@ def getFeaturesByExtent(pathId, timestampId, extent, propertyFilter = None, toke
|
|
|
146
146
|
extent = sanitize.validBounds('extent', extent, True)
|
|
147
147
|
propertyFilter = sanitize.validObject('propertyFilter', propertyFilter, False)
|
|
148
148
|
listAll = sanitize.validBool('listAll', listAll, True)
|
|
149
|
-
pageStart = sanitize.
|
|
149
|
+
pageStart = sanitize.validObject('pageStart', pageStart, False)
|
|
150
150
|
|
|
151
151
|
p = geometry.Polygon( [(extent['xMin'], extent['yMin']), (extent['xMin'], extent['yMax']),(extent['xMax'], extent['yMax']),(extent['xMax'], extent['yMin'])] )
|
|
152
152
|
p = gpd.GeoDataFrame({'geometry':[p]})
|
|
@@ -195,7 +195,7 @@ def listFeatures(pathId, timestampId, token = None, listAll = True, pageStart =
|
|
|
195
195
|
timestampId = sanitize.validUuid('timestampId', timestampId, True)
|
|
196
196
|
token = sanitize.validString('token', token, False)
|
|
197
197
|
listAll = sanitize.validBool('listAll', listAll, True)
|
|
198
|
-
pageStart = sanitize.
|
|
198
|
+
pageStart = sanitize.validObject('pageStart', pageStart, False)
|
|
199
199
|
|
|
200
200
|
body = {'pageStart': pageStart}
|
|
201
201
|
|
ellipsis/sanitize.py
CHANGED
|
@@ -18,6 +18,25 @@ def validUuid(name, value, required):
|
|
|
18
18
|
raise ValueError(name + ' must be of type string and be a uuid')
|
|
19
19
|
return(value)
|
|
20
20
|
|
|
21
|
+
def validResolution(name, value, required):
|
|
22
|
+
if not required and type(value) == type(None):
|
|
23
|
+
return
|
|
24
|
+
|
|
25
|
+
if type(value) != type({}):
|
|
26
|
+
raise ValueError(name + ' must be of type dictionary with properties min and max as float')
|
|
27
|
+
|
|
28
|
+
if 'min' not in value.keys() or 'max' not in value.keys():
|
|
29
|
+
raise ValueError(name + ' must be of type dictionary with properties min and max as float')
|
|
30
|
+
|
|
31
|
+
try:
|
|
32
|
+
value = {'min': float(value['min']), 'max':float(value['max']) }
|
|
33
|
+
except:
|
|
34
|
+
raise ValueError(name + ' must be of type dictionary with properties min and max as float')
|
|
35
|
+
|
|
36
|
+
return(value)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
|
|
21
40
|
def validDateRange(name, value, required):
|
|
22
41
|
|
|
23
42
|
if not required and type(value) == type(None):
|
ellipsis/util/root.py
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
ellipsis/__init__.py,sha256=
|
|
1
|
+
ellipsis/__init__.py,sha256=93GninuGlrB3AOG4w3NKKwibcLa_Tbx-8psQkH0QGGY,232
|
|
2
2
|
ellipsis/apiManager.py,sha256=QU0LzYMivctlzUN9yLOTIF1ypAwvI9xsD9Nw_kJT1Yk,3302
|
|
3
|
-
ellipsis/sanitize.py,sha256=
|
|
3
|
+
ellipsis/sanitize.py,sha256=YCxtl9DFA7oipf_oiAkGUrbvB3J3ZWUFNuk06s8Byq4,9745
|
|
4
4
|
ellipsis/account/__init__.py,sha256=K40DMBaUDSxt3rO2WZv63Wmpfy49ocqBxvWqyIYHR24,92
|
|
5
5
|
ellipsis/account/root.py,sha256=29IGUJavfXC9wLC_Fxzy1cdCbnP4QPmbYlE-H6VP088,1285
|
|
6
6
|
ellipsis/account/accessToken/__init__.py,sha256=ivwhK1eC4g74PAKaeTReb1QhIpKXyvmfdqZV6wDY-EY,66
|
|
7
7
|
ellipsis/account/accessToken/root.py,sha256=TYo8wTyWyzytaqOTsuQC-Vn3y7BhYMC88EItZafpISA,1281
|
|
8
8
|
ellipsis/path/__init__.py,sha256=2AL0qA5fzPYtizw-baHA8l5J4MTG55giSdxJ3HrHzl8,398
|
|
9
|
-
ellipsis/path/root.py,sha256=
|
|
9
|
+
ellipsis/path/root.py,sha256=vw8p36-_rLAHuy7WUv793HRftxa3VIPmpmWtSdJiXOE,7609
|
|
10
10
|
ellipsis/path/file/__init__.py,sha256=jpXoU1agFnEH1XzLSigJ8uNRC-5534I4kskuNpt-6us,85
|
|
11
11
|
ellipsis/path/file/root.py,sha256=kXUfHXd_OmhjuCdDPS5vpCBoqlFPSfkAOAKex_1e6M8,829
|
|
12
12
|
ellipsis/path/folder/__init__.py,sha256=HCeAZAWZSqUnWiSQYJjsVFe6AI9uKSS8tb5uTkSeAtI,91
|
|
@@ -18,13 +18,13 @@ ellipsis/path/invite/root.py,sha256=lX13eUE3FYrAElOuVMg89XEIrdYbwsJAl5_8OV1f92g,
|
|
|
18
18
|
ellipsis/path/member/__init__.py,sha256=1mu6v4LzTY5mZHNniCCLRtJo7MkSZleUT-xJQ7vMZOM,56
|
|
19
19
|
ellipsis/path/member/root.py,sha256=YBYyQsBp2YQNfI_ffvyA-Y_Fhs9UoYvMKYAXsrUaslg,1071
|
|
20
20
|
ellipsis/path/raster/__init__.py,sha256=xWEsdpQxsqnwSdRqmZujS3pEUAmemHmUCtMKCaWLK0M,217
|
|
21
|
-
ellipsis/path/raster/root.py,sha256
|
|
21
|
+
ellipsis/path/raster/root.py,sha256=-y0SEukHEYUDvyJyDI1x7gtcDm-Wum_Ze7ekSYJr6O4,1749
|
|
22
22
|
ellipsis/path/raster/style/__init__.py,sha256=mxlqVtSd2dsKai3DAVQjtNsh2KnTrZVyF8loRwUNT7E,61
|
|
23
23
|
ellipsis/path/raster/style/root.py,sha256=D01E-z2F1OrbLJgUF48cttH6chM0K94Vk2dhwENg8OY,1547
|
|
24
24
|
ellipsis/path/raster/timestamp/__init__.py,sha256=x7uCEnVHmNFS686Iaw8bD0zv6lfQpEdYx6RZpcnQ5-4,859
|
|
25
25
|
ellipsis/path/raster/timestamp/root.py,sha256=BROg-wummgaGMVr2SjV7jN1VS3NvgQVBipuq_QzgLmk,12671
|
|
26
26
|
ellipsis/path/raster/timestamp/file/__init__.py,sha256=Ln9_dQ4-PMwb5VP--Qh09IV5zmr-47RShpe0-f_NVh4,97
|
|
27
|
-
ellipsis/path/raster/timestamp/file/root.py,sha256=
|
|
27
|
+
ellipsis/path/raster/timestamp/file/root.py,sha256=GvcSSEONJveX0KfazqXLmE-SPP-gSZIjwPKZKO-diFM,3891
|
|
28
28
|
ellipsis/path/raster/timestamp/order/__init__.py,sha256=4YEK4XW9TM-HsjoFlFeyGMtI3OKX2VCXfb4NsTsugBo,74
|
|
29
29
|
ellipsis/path/raster/timestamp/order/root.py,sha256=zWcfI_q9KlfevzyvwWY8ni27KCvOyAiaJvohVfasjXg,1176
|
|
30
30
|
ellipsis/path/usage/__init__.py,sha256=TfHolUnnQFh7VuE9eG3-DGEc5ctyj4PzPxDNVgoU5tg,82
|
|
@@ -36,9 +36,9 @@ ellipsis/path/vector/featureProperty/root.py,sha256=-RdDE-F_MiLsPjKSOrRexijJ94lq
|
|
|
36
36
|
ellipsis/path/vector/style/__init__.py,sha256=riiDnL4FDq4EFhSYAYHBSe_o5oltRTSrj4sc72F6IVQ,63
|
|
37
37
|
ellipsis/path/vector/style/root.py,sha256=09PsRbCJ35YV8bl8xoWFoeGRpdmf5IBmmqwhRj30OTM,1641
|
|
38
38
|
ellipsis/path/vector/timestamp/__init__.py,sha256=n0ncRxXoQIDX1WeV0lbpJH1BND793CdZ5swGgeu1Kfk,330
|
|
39
|
-
ellipsis/path/vector/timestamp/root.py,sha256=
|
|
39
|
+
ellipsis/path/vector/timestamp/root.py,sha256=bxR2WVPNjwCemiMlGG2kswxscCBlVcux6OlSgCJcsZk,8620
|
|
40
40
|
ellipsis/path/vector/timestamp/feature/__init__.py,sha256=miaLCHkogL9KJ_eUr4K_N15BShAe2ivcppDFJuE_SgI,210
|
|
41
|
-
ellipsis/path/vector/timestamp/feature/root.py,sha256=
|
|
41
|
+
ellipsis/path/vector/timestamp/feature/root.py,sha256=5tmX_UHj8VZeYRhsLwf4P82vprL7Lsee-ViGncKWyXA,13019
|
|
42
42
|
ellipsis/path/vector/timestamp/feature/message/__init__.py,sha256=XfX3MIa4RjpToFnxNyfxCKTvRlNtJFRQ44j31wDyhGc,100
|
|
43
43
|
ellipsis/path/vector/timestamp/feature/message/root.py,sha256=isLzkITTiluKoIsH0PYT0K5Cr-LBzTA0TSE4-2tZU5M,3949
|
|
44
44
|
ellipsis/path/vector/timestamp/feature/series/__init__.py,sha256=vPi57QdUPTEnQE31abgxzwWU3Gzu-Xxi3ZVD4z5MMwg,107
|
|
@@ -50,11 +50,11 @@ ellipsis/path/vector/timestamp/order/root.py,sha256=FB3AAbsp46Wv2vtvuFLx_djwh_Qn
|
|
|
50
50
|
ellipsis/user/__init__.py,sha256=um_b42pc2otFiQRGqMajcEtONQpC2ei4r-EY3j7bsfQ,43
|
|
51
51
|
ellipsis/user/root.py,sha256=dsMK6wGBdeCmOd3YsbIv9cEcQ6tAiSGr0jmtBhQl5-0,484
|
|
52
52
|
ellipsis/util/__init__.py,sha256=A3BEF6O5qTRU90yoaZDI-xF8R1WAFuh1fdxwWKd1Uvw,628
|
|
53
|
-
ellipsis/util/root.py,sha256=
|
|
53
|
+
ellipsis/util/root.py,sha256=d7CYEhiGb6RY5Ep7lDmIderiRfXnnPtW8f9ZJu0VTgg,19434
|
|
54
54
|
ellipsis/view/__init__.py,sha256=91KyJzbSvwSP9hvJQyo1LLM48b5NixLz6G40I9h6sdY,67
|
|
55
55
|
ellipsis/view/root.py,sha256=6actiBwIsM0f7sJhQl_U4j-C6Dhe0z5XGGtxIOIKdY8,1726
|
|
56
|
-
ellipsis-3.1.
|
|
57
|
-
ellipsis-3.1.
|
|
58
|
-
ellipsis-3.1.
|
|
59
|
-
ellipsis-3.1.
|
|
60
|
-
ellipsis-3.1.
|
|
56
|
+
ellipsis-3.1.6.dist-info/LICENSE,sha256=7EI8xVBu6h_7_JlVw-yPhhOZlpY9hP8wal7kHtqKT_E,1074
|
|
57
|
+
ellipsis-3.1.6.dist-info/METADATA,sha256=P5wVbXyxs2EB-Zu38neKQcTtkJGuko0-e6Et4oc4wDY,1805
|
|
58
|
+
ellipsis-3.1.6.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
|
59
|
+
ellipsis-3.1.6.dist-info/top_level.txt,sha256=eG8gfaVDyprKdb-dsGSh_lFMSa3DiZCsJFqze239RjA,9
|
|
60
|
+
ellipsis-3.1.6.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|