pyvlasiator 0.1.1__py3-none-any.whl → 0.1.2__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 pyvlasiator might be problematic. Click here for more details.

pyvlasiator/plot/plot.py CHANGED
@@ -867,6 +867,7 @@ def vdfslice(
867
867
  center: str = None,
868
868
  weight: str = "particle",
869
869
  flimit: float = -1.0,
870
+ addcolorbar: bool = True,
870
871
  **kwargs,
871
872
  ):
872
873
  v1, v2, r1, r2, weights, strx, stry, str_title = prep_vdf(
@@ -908,9 +909,10 @@ def vdfslice(
908
909
  ax.grid(color="grey", linestyle="-")
909
910
  ax.tick_params(direction="in")
910
911
 
911
- cb = plt.colorbar(h[3], ax=ax, fraction=0.04, pad=0.02)
912
- cb.ax.tick_params(which="both", direction="in")
913
- cb_title = cb.ax.set_ylabel("f(v)")
912
+ if addcolorbar:
913
+ cb = plt.colorbar(h[3], ax=ax, fraction=0.04, pad=0.02)
914
+ cb.ax.tick_params(which="both", direction="in")
915
+ cb_title = cb.ax.set_ylabel("f(v)")
914
916
 
915
917
  # TODO: Draw vector of magnetic field direction
916
918
  # if slicetype in ("xy", "xz", "yz"):
@@ -405,14 +405,16 @@ class Vlsv:
405
405
  )
406
406
  if hasattr(cellids, "__len__"): # part of cells requested
407
407
  return np.float32(raw)
408
-
409
- if sorted:
410
- if raw.ndim == 1:
411
- v = raw[self.cellindex]
408
+ elif cellids == -1:
409
+ if sorted:
410
+ if raw.ndim == 1:
411
+ v = raw[self.cellindex]
412
+ else:
413
+ v = raw[self.cellindex, :]
414
+ if v.dtype == np.float64: # 32-bit is enough for analysis
415
+ v = np.float32(v)
412
416
  else:
413
- v = raw[self.cellindex, :]
414
- if v.dtype == np.float64: # 32-bit is enough for analysis
415
- v = np.float32(v)
417
+ v = raw
416
418
  else:
417
419
  v = raw
418
420
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pyvlasiator
3
- Version: 0.1.1
3
+ Version: 0.1.2
4
4
  Summary: Python utilities for processing Vlasiator data
5
5
  Author: Hongyang Zhou
6
6
  Author-email: hyzhou@umich.edu
@@ -1,11 +1,11 @@
1
1
  pyvlasiator/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  pyvlasiator/plot/__init__.py,sha256=VFZ3mB3iGHqqDVpsyMGLDUov8FiDydMdAhvtbnTvWtM,235
3
- pyvlasiator/plot/plot.py,sha256=RZqy5zFRds0FVpbLlbAugYBnHKIMdflcuWRluTXF1nQ,34012
3
+ pyvlasiator/plot/plot.py,sha256=BbF4gSevO9mA_ZP4ztN-dEzL82vgpwOdimPxD3OuwhE,34076
4
4
  pyvlasiator/pyvlasiator.py,sha256=11dp6PsBPHacbGHtzI7mdS8NreiBNYuwbI5cx_5bfDw,62
5
5
  pyvlasiator/vlsv/__init__.py,sha256=T1_Znxt_H7XL-Al5IG0C_CKBw_u2VkeVQ3O1INH29po,81
6
- pyvlasiator/vlsv/reader.py,sha256=MdnmJCphhGJqLNYxxfv3ku1plyZ9p_jCeGLFejStTh8,35046
6
+ pyvlasiator/vlsv/reader.py,sha256=wWeQhW1vjuWVz9Wu0wIotYwyuDr2h1iKY0afV6JSUZM,35145
7
7
  pyvlasiator/vlsv/variables.py,sha256=JTVGUBTs8CX7aonW_vVNKNca3hNsVsr3DXL7NesqeTo,5987
8
- pyvlasiator-0.1.1.dist-info/LICENSE.md,sha256=UbZmGbnA73ReemkiNPRNfqgGtpPwiGFJiOZo0gxiP_o,1125
9
- pyvlasiator-0.1.1.dist-info/METADATA,sha256=i38oR-MaUx3JTcO_79xXisA6KWYnz3OE4Qhi39mZG1U,1702
10
- pyvlasiator-0.1.1.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
11
- pyvlasiator-0.1.1.dist-info/RECORD,,
8
+ pyvlasiator-0.1.2.dist-info/LICENSE.md,sha256=UbZmGbnA73ReemkiNPRNfqgGtpPwiGFJiOZo0gxiP_o,1125
9
+ pyvlasiator-0.1.2.dist-info/METADATA,sha256=SlzurMw7FFwJH1-LqrRUCwsi64tESxI1IX5MlU46hRs,1702
10
+ pyvlasiator-0.1.2.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
11
+ pyvlasiator-0.1.2.dist-info/RECORD,,