starplot 0.15.2__py2.py3-none-any.whl → 0.15.4__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.

Potentially problematic release.


This version of starplot might be problematic. Click here for more details.

starplot/__init__.py CHANGED
@@ -1,6 +1,6 @@
1
1
  """Star charts and maps of the sky"""
2
2
 
3
- __version__ = "0.15.2"
3
+ __version__ = "0.15.4"
4
4
 
5
5
  from .base import BasePlot # noqa: F401
6
6
  from .map import MapPlot, Projection # noqa: F401
@@ -499,7 +499,11 @@ hips = {
499
499
  [93194, 92420],
500
500
  [92420, 91971],
501
501
  ],
502
- "men": [[29271, 23467]],
502
+ "men": [
503
+ [29271, 25918],
504
+ [25918, 22871],
505
+ [22871, 23467],
506
+ ],
503
507
  "mic": [[102831, 103738], [103738, 105140], [105140, 105382]],
504
508
  "mon": [
505
509
  [31978, 31216],
@@ -897,6 +897,7 @@ CONSTELLATION_HIPS = [
897
897
  22783,
898
898
  22797,
899
899
  22845,
900
+ 22871,
900
901
  22957,
901
902
  23015,
902
903
  23040,
@@ -921,6 +922,7 @@ CONSTELLATION_HIPS = [
921
922
  25428,
922
923
  25606,
923
924
  25859,
925
+ 25918,
924
926
  25930,
925
927
  25985,
926
928
  26069,
Binary file
starplot/data/stars.py CHANGED
@@ -1,3 +1,5 @@
1
+ from functools import cache
2
+
1
3
  import ibis
2
4
  from ibis import _
3
5
 
@@ -456,15 +458,15 @@ class StarCatalog:
456
458
  """
457
459
 
458
460
 
459
- def load(extent=None, catalog: StarCatalog = StarCatalog.BIG_SKY_MAG11, filters=None):
460
- filters = filters or []
461
+ @cache
462
+ def read_catalog(catalog: StarCatalog = StarCatalog.BIG_SKY_MAG11, table_name="stars"):
461
463
  con = db.connect()
462
464
 
463
465
  if catalog == StarCatalog.BIG_SKY_MAG11:
464
- stars = con.read_parquet(DataFiles.BIG_SKY_MAG11, "stars")
466
+ stars = con.read_parquet(DataFiles.BIG_SKY_MAG11, table_name)
465
467
  elif catalog == StarCatalog.BIG_SKY:
466
468
  bigsky.download_if_not_exists()
467
- stars = con.read_parquet(DataFiles.BIG_SKY, "stars")
469
+ stars = con.read_parquet(DataFiles.BIG_SKY, table_name)
468
470
  else:
469
471
  raise ValueError("Unrecognized star catalog.")
470
472
 
@@ -481,9 +483,6 @@ def load(extent=None, catalog: StarCatalog = StarCatalog.BIG_SKY_MAG11, filters=
481
483
  rowid=ibis.row_number(),
482
484
  )
483
485
 
484
- if extent:
485
- stars = stars.filter(stars.geometry.intersects(extent))
486
-
487
486
  stars = stars.join(
488
487
  designations,
489
488
  [
@@ -493,6 +492,16 @@ def load(extent=None, catalog: StarCatalog = StarCatalog.BIG_SKY_MAG11, filters=
493
492
  how="left",
494
493
  )
495
494
 
495
+ return stars
496
+
497
+
498
+ def load(extent=None, catalog: StarCatalog = StarCatalog.BIG_SKY_MAG11, filters=None):
499
+ filters = filters or []
500
+ stars = read_catalog(catalog)
501
+
502
+ if extent:
503
+ stars = stars.filter(stars.geometry.intersects(extent))
504
+
496
505
  if filters:
497
506
  return stars.filter(*filters)
498
507
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: starplot
3
- Version: 0.15.2
3
+ Version: 0.15.4
4
4
  Summary: Star charts and maps of the sky
5
5
  Keywords: astronomy,stars,charts,maps,constellations,sky,plotting
6
6
  Author-email: Steve Berardi <hello@steveberardi.com>
@@ -24,8 +24,8 @@ Requires-Dist: pyarrow >= 14.0.2
24
24
  Requires-Dist: pyogrio >= 0.10.0
25
25
  Requires-Dist: rtree >= 1.2.0
26
26
  Requires-Dist: requests >= 2.31.0
27
- Requires-Dist: duckdb >= 1.1.3
28
- Requires-Dist: ibis-framework[duckdb, geospatial] >= 9.5.0
27
+ Requires-Dist: duckdb ~= 1.1.3
28
+ Requires-Dist: ibis-framework[duckdb, geospatial] ~= 9.5.0
29
29
  Project-URL: Documentation, https://starplot.dev
30
30
  Project-URL: Home, https://starplot.dev
31
31
  Project-URL: Source, https://github.com/steveberardi/starplot
@@ -1,4 +1,4 @@
1
- starplot/__init__.py,sha256=5d7xb4i1-GKgfIz9qBhZnM1Bv0YpbNbdMfrlcsl5kRI,558
1
+ starplot/__init__.py,sha256=zQ2JDEfSJixS0dULL0hIuq1yaqhzGjTkeDyvFeHU0FE,558
2
2
  starplot/base.py,sha256=JjBqM96gPoBFngbxZ5dsHDKwbsBsrviEipAlljtl8YU,42842
3
3
  starplot/callables.py,sha256=_zDGCAJTqqNLvCtcIt4PVEe2L0Ggvl6pj-7ZFI-0zqI,4043
4
4
  starplot/cli.py,sha256=W-V-h1DeD8zwzdhYuQ-i26LSZWYcS_NJ0zRXa-dmy1o,711
@@ -17,17 +17,17 @@ starplot/utils.py,sha256=49m8QXJl188Pgpef_82gyykly7ZjfAuHVEcSA5QFITA,3720
17
17
  starplot/warnings.py,sha256=uKvGSAVpWKZIHMKxxegO5owFJnKvBYLyq3pJatD0qQ4,594
18
18
  starplot/data/__init__.py,sha256=3M_uHlwyIsc9cyfabnOp-6CoXoMteYAaWuj4St9_1BE,308
19
19
  starplot/data/bigsky.py,sha256=SiHzzhoy-DAZpJ-Q_-lmJqHRLwTKgosaVOEXYWQ94PI,2820
20
- starplot/data/constellation_lines.py,sha256=Uz5Qd754ayXYQdUsPR5R1QN3AxK0yewgp1c0rOqMH7w,19281
21
- starplot/data/constellation_stars.py,sha256=v5Xd8eXlzaNPFuJ7U_kB0pP3FT_bXGToo6gHw-jbQIk,38199
20
+ starplot/data/constellation_lines.py,sha256=RLyFSoxGRL7kj9gGT4DDUubClKZEDu5wGUMG3PlpYfY,19344
21
+ starplot/data/constellation_stars.py,sha256=l2GeyJWuVtzH-MIw1oGR6jeMBvfqX-q-S2V_ilcEZG8,38221
22
22
  starplot/data/constellations.py,sha256=E-wEyZ4W5lcUS_StH26F9NMRsFyFs-utGxGcfRK7zBk,15484
23
23
  starplot/data/db.py,sha256=77oWr2HkZ95K_mG4vLc-ivP_SOFIiFYwoqrtTw-YWtk,384
24
24
  starplot/data/dsos.py,sha256=tx-6oDzKPthg-nxfda2ah5t10USdyrckP4UjM5k-e10,1237
25
25
  starplot/data/ecliptic.py,sha256=Qre9YdFbTC9mAx-vd2C0Ou4CsnRehIScnTpmEUDDYcM,4638
26
- starplot/data/stars.py,sha256=PWAszqlIDpndySIW-uLAibCwbPia_AE6nK_w3pAQxz0,11862
26
+ starplot/data/stars.py,sha256=qYhP8Cr2zDR1vke7AJznTcVMtD6w92jW97XnGCAqdsw,12046
27
27
  starplot/data/utils.py,sha256=RPk3bnfL-KtjMk1VQygDD27INz_gEya_B1hu7X4K8hU,772
28
- starplot/data/library/bigsky.0.4.0.stars.mag11.parquet,sha256=Mc7N63Naja2eJMygDtJgUUzJSc6IuvEL2iLzDzC6l00,38885096
28
+ starplot/data/library/bigsky.0.4.0.stars.mag11.parquet,sha256=-_D6bghArUh1cmOKktxmmBFQNThiCWjVleI0wduP1GI,38884673
29
29
  starplot/data/library/de421_2001.bsp,sha256=ymkZigAd8Vgscq_DYkdR4nZ1VGD5wwPd-sxe6HiiTns,5341104
30
- starplot/data/library/sky.db,sha256=ZCV2VihN_0iEMW-eHfG1QFAWQfyCaFIlRCnZa7dKDoU,38023168
30
+ starplot/data/library/sky.db,sha256=qZg6jHG6XbgndpEn_sB4oHloccvEZRuSLER9idQQ6fU,38023168
31
31
  starplot/models/__init__.py,sha256=qi4arVatzEcR9TAbHadSbhq8xRhSb1_Br3UKNv4FP7o,330
32
32
  starplot/models/base.py,sha256=zuHcRSs4eSyIwtyUTsAk9a73bnIW2gfWh7Ze_zt8Tq0,1623
33
33
  starplot/models/constellation.py,sha256=qfBcWyQRL2m83wNIKiPk-4bGRblYvabxymW6TJ0nXFI,3355
@@ -92,8 +92,8 @@ starplot/styles/fonts-library/inter/Inter-SemiBoldItalic.ttf,sha256=HhKJRT16iVz7
92
92
  starplot/styles/fonts-library/inter/Inter-Thin.ttf,sha256=TDktzIrZFvD533VZq1VjsB3ZT587LbNGF_45LgAGAzk,403404
93
93
  starplot/styles/fonts-library/inter/Inter-ThinItalic.ttf,sha256=X8Ca-UpEf65vgsAPFd-u-ernxWDmy-RtPoRSQBmldKo,410232
94
94
  starplot/styles/fonts-library/inter/LICENSE.txt,sha256=JiSB6ERSGzJvXs0FPlm5jIstp4yO4b27boF0MF5Uk1o,4380
95
- starplot-0.15.2.dist-info/entry_points.txt,sha256=Sm6jC6h_RcaMGC8saLnYmT0SdhcF9_rMeQIiHneLHyc,46
96
- starplot-0.15.2.dist-info/LICENSE,sha256=jcjClHF4BQwhz-kDgia-KphO9Zxu0rCa2BbiA7j1jeU,1070
97
- starplot-0.15.2.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
98
- starplot-0.15.2.dist-info/METADATA,sha256=QrXm2Vs4JMkLq3ypgai1c2-x68kOnghRdrGRhXGQ9Yo,4258
99
- starplot-0.15.2.dist-info/RECORD,,
95
+ starplot-0.15.4.dist-info/entry_points.txt,sha256=Sm6jC6h_RcaMGC8saLnYmT0SdhcF9_rMeQIiHneLHyc,46
96
+ starplot-0.15.4.dist-info/LICENSE,sha256=jcjClHF4BQwhz-kDgia-KphO9Zxu0rCa2BbiA7j1jeU,1070
97
+ starplot-0.15.4.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
98
+ starplot-0.15.4.dist-info/METADATA,sha256=SwrPxIPfGOWHxstYJBPiioWIno_L1_ONfbGqM6xfxhY,4258
99
+ starplot-0.15.4.dist-info/RECORD,,