ncplot 0.3.10__tar.gz → 0.3.13__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.
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: ncplot
3
- Version: 0.3.10
3
+ Version: 0.3.13
4
4
  Summary: Interactive viewing of NetCDF data
5
5
  Home-page: https://github.com/pmlmodelling/ncplot
6
6
  Author: Robert Wilson
@@ -31,6 +31,19 @@ Requires-Dist: jupyter_bokeh
31
31
  Requires-Dist: datashader; python_version <= "3.10"
32
32
  Provides-Extra: complete
33
33
  Requires-Dist: geoviews; extra == "complete"
34
+ Dynamic: author
35
+ Dynamic: author-email
36
+ Dynamic: classifier
37
+ Dynamic: description
38
+ Dynamic: description-content-type
39
+ Dynamic: home-page
40
+ Dynamic: license-file
41
+ Dynamic: maintainer
42
+ Dynamic: project-url
43
+ Dynamic: provides-extra
44
+ Dynamic: requires-dist
45
+ Dynamic: requires-python
46
+ Dynamic: summary
34
47
 
35
48
 
36
49
 
@@ -495,7 +495,7 @@ def view(x, vars=None, autoscale=True, out=None, **kwargs):
495
495
  coord_list = [x for x in coord_list if x in list(ds.dims)]
496
496
 
497
497
  coord_df = pd.DataFrame(
498
- {"coord": coord_list, "length": [len(ds.coords[x].values) for x in coord_list]}
498
+ {"coord": coord_list, "coord_length": [len(ds.coords[x].values) for x in coord_list]}
499
499
  )
500
500
 
501
501
  # It's possible there are still 2 time variables in the dimensions which could cause problems...
@@ -515,7 +515,7 @@ def view(x, vars=None, autoscale=True, out=None, **kwargs):
515
515
  if (len(ds[lon_name].values) > 1) and (len(ds[lat_name].values) > 1):
516
516
  spatial_map = True
517
517
 
518
- if len([x for x in coord_df.length if x > 1]) == 1 and spatial_map is False:
518
+ if len([x for x in coord_df.coord_length if x > 1]) == 1 and spatial_map is False:
519
519
 
520
520
  df = ds.to_dataframe()
521
521
  if nc_vars is not None:
@@ -556,12 +556,11 @@ def view(x, vars=None, autoscale=True, out=None, **kwargs):
556
556
  return None
557
557
 
558
558
  # heat map where 2 coords have more than 1 value, not a spatial map
559
- if len([x for x in coord_df.length if x > 1]) == 2 and spatial_map is False:
559
+ if len([x for x in coord_df.coord_length if x > 1]) == 2 and spatial_map is False:
560
560
 
561
561
  df = ds.to_dataframe().reset_index()
562
- x_var = coord_df.query("length > 1").reset_index().coord[0]
563
- y_var = coord_df.query("length > 1").reset_index().coord[1]
564
-
562
+ x_var = coord_df.query("coord_length > 1").reset_index().coord[0]
563
+ y_var = coord_df.query("coord_length > 1").reset_index().coord[1]
565
564
  selection = [x for x in df.columns if x in vars or x == x_var or x == y_var]
566
565
 
567
566
  df = df.loc[:, selection].melt([x_var, y_var]).drop_duplicates()
@@ -696,18 +695,18 @@ def view(x, vars=None, autoscale=True, out=None, **kwargs):
696
695
  return None
697
696
 
698
697
  # heat map where 3 coords have more than 1 value, and one of them is time. Not a spatial map though
699
- if len([x for x in coord_df.length if x > 1]) == 3:
698
+ if len([x for x in coord_df.coord_length if x > 1]) == 3:
700
699
 
701
700
  non_map = True
702
701
 
703
702
  if lon_name is not None and lat_name is not None:
704
703
  if (lon_name is not None) and (lon_name in list(ds.coords)):
705
- lons = int(coord_df.query("coord == @lon_name").length)
704
+ lons = int(coord_df.query("coord == @lon_name").coord_length.values[0])
706
705
  else:
707
706
  lons = 0
708
707
 
709
708
  if (lat_name) is not None and (lat_name in list(ds.coords)):
710
- lats = int(coord_df.query("coord == @lat_name").length)
709
+ lats = int(coord_df.query("coord == @lat_name").coord_length.values[0])
711
710
  else:
712
711
  lats = 0
713
712
 
@@ -725,7 +724,7 @@ def view(x, vars=None, autoscale=True, out=None, **kwargs):
725
724
 
726
725
  if time_name in coord_list and time_in and non_map:
727
726
 
728
- if coord_df.query("coord == @time_name").length.values > 1:
727
+ if coord_df.query("coord == @time_name").coord_length.values[0] > 1:
729
728
 
730
729
  df = ds.to_dataframe().reset_index()
731
730
  for x in list(ds.coords):
@@ -1,6 +1,7 @@
1
1
  LICENSE
2
2
  MANIFEST.in
3
3
  README.md
4
+ pyproject.toml
4
5
  requirements.txt
5
6
  setup.py
6
7
  ncplot/__init__.py
@@ -0,0 +1,5 @@
1
+ # pyproject.toml
2
+ [build-system]
3
+ # XXX: If your project needs other packages to build properly, add them to this list.
4
+ requires = ["setuptools >= 42.0.0"]
5
+ build-backend = "setuptools.build_meta"
@@ -37,7 +37,7 @@ extras_require: dict() = {
37
37
  extras_require["complete"] = ["geoviews"]
38
38
 
39
39
  setup(name='ncplot',
40
- version='0.3.10',
40
+ version='0.3.13',
41
41
  description=DESCRIPTION,
42
42
  long_description=long_description,
43
43
  long_description_content_type='text/markdown',
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