kerykeion 4.0.6__py3-none-any.whl → 4.12.3__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 kerykeion might be problematic. Click here for more details.
- kerykeion/__init__.py +4 -96
- kerykeion/aspects/__init__.py +2 -2
- kerykeion/aspects/aspects_utils.py +174 -0
- kerykeion/aspects/natal_aspects.py +51 -222
- kerykeion/aspects/synastry_aspects.py +45 -23
- kerykeion/astrological_subject.py +453 -199
- kerykeion/charts/__init__.py +1 -1
- kerykeion/charts/charts_utils.py +339 -5
- kerykeion/charts/kerykeion_chart_svg.py +441 -500
- kerykeion/charts/templates/chart.xml +362 -330
- kerykeion/enums.py +50 -0
- kerykeion/fetch_geonames.py +16 -25
- kerykeion/kr_types/__init__.py +7 -0
- kerykeion/kr_types/chart_types.py +33 -32
- kerykeion/kr_types/kerykeion_exception.py +1 -1
- kerykeion/kr_types/kr_literals.py +87 -44
- kerykeion/kr_types/kr_models.py +42 -78
- kerykeion/kr_types/settings_models.py +163 -0
- kerykeion/relationship_score.py +7 -13
- kerykeion/report.py +3 -0
- kerykeion/settings/__init__.py +1 -1
- kerykeion/settings/kerykeion_settings.py +13 -183
- kerykeion/settings/kr.config.json +9 -9
- kerykeion/utilities.py +184 -22
- {kerykeion-4.0.6.dist-info → kerykeion-4.12.3.dist-info}/METADATA +142 -32
- kerykeion-4.12.3.dist-info/RECORD +32 -0
- {kerykeion-4.0.6.dist-info → kerykeion-4.12.3.dist-info}/WHEEL +1 -1
- kerykeion-4.0.6.dist-info/RECORD +0 -29
- {kerykeion-4.0.6.dist-info → kerykeion-4.12.3.dist-info}/LICENSE +0 -0
- {kerykeion-4.0.6.dist-info → kerykeion-4.12.3.dist-info}/entry_points.txt +0 -0
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
# -*- coding: utf-8 -*-
|
|
2
2
|
"""
|
|
3
|
-
This is part of Kerykeion (C)
|
|
3
|
+
This is part of Kerykeion (C) 2024 Giacomo Battaglia
|
|
4
4
|
"""
|
|
5
5
|
|
|
6
6
|
from kerykeion import AstrologicalSubject
|
|
7
7
|
from pathlib import Path
|
|
8
8
|
from typing import Union
|
|
9
|
+
from functools import cached_property
|
|
9
10
|
|
|
10
11
|
from kerykeion.aspects.natal_aspects import NatalAspects
|
|
12
|
+
from kerykeion.settings.kerykeion_settings import get_settings
|
|
13
|
+
from kerykeion.aspects.aspects_utils import planet_id_decoder, get_aspect_from_two_points, get_active_points_list
|
|
11
14
|
|
|
12
15
|
|
|
13
16
|
class SynastryAspects(NatalAspects):
|
|
@@ -21,49 +24,65 @@ class SynastryAspects(NatalAspects):
|
|
|
21
24
|
kr_object_two: AstrologicalSubject,
|
|
22
25
|
new_settings_file: Union[Path, None] = None,
|
|
23
26
|
):
|
|
27
|
+
# Subjects
|
|
24
28
|
self.first_user = kr_object_one
|
|
25
29
|
self.second_user = kr_object_two
|
|
26
30
|
|
|
31
|
+
# Settings
|
|
27
32
|
self.new_settings_file = new_settings_file
|
|
28
|
-
self.
|
|
33
|
+
self.settings = get_settings(self.new_settings_file)
|
|
29
34
|
|
|
30
|
-
self.
|
|
31
|
-
self.
|
|
35
|
+
self.celestial_points = self.settings["celestial_points"]
|
|
36
|
+
self.aspects_settings = self.settings["aspects"]
|
|
37
|
+
self.axes_orbit_settings = self.settings["general_settings"]["axes_orbit"]
|
|
32
38
|
|
|
33
|
-
|
|
39
|
+
# Private variables of the aspects
|
|
40
|
+
self._all_aspects: Union[list, None] = None
|
|
41
|
+
self._relevant_aspects: Union[list, None] = None
|
|
42
|
+
|
|
43
|
+
@cached_property
|
|
44
|
+
def all_aspects(self):
|
|
34
45
|
"""
|
|
35
46
|
Return all the aspects of the points in the natal chart in a dictionary,
|
|
36
47
|
first all the individual aspects of each planet, second the aspects
|
|
37
48
|
whiteout repetitions.
|
|
38
49
|
"""
|
|
39
50
|
|
|
40
|
-
|
|
41
|
-
|
|
51
|
+
if self._all_aspects is not None:
|
|
52
|
+
return self._all_aspects
|
|
53
|
+
|
|
54
|
+
# Celestial Points Lists
|
|
55
|
+
first_active_points_list = get_active_points_list(self.first_user, self.settings)
|
|
56
|
+
second_active_points_list = get_active_points_list(self.second_user, self.settings)
|
|
42
57
|
|
|
43
58
|
self.all_aspects_list = []
|
|
44
59
|
|
|
45
|
-
for first in range(len(
|
|
60
|
+
for first in range(len(first_active_points_list)):
|
|
46
61
|
# Generates the aspects list whitout repetitions
|
|
47
|
-
for second in range(len(
|
|
48
|
-
verdict, name, orbit, aspect_degrees,
|
|
49
|
-
|
|
62
|
+
for second in range(len(second_active_points_list)):
|
|
63
|
+
verdict, name, orbit, aspect_degrees, aid, diff = get_aspect_from_two_points(
|
|
64
|
+
self.aspects_settings,
|
|
65
|
+
first_active_points_list[first]["abs_pos"],
|
|
66
|
+
second_active_points_list[second]["abs_pos"],
|
|
50
67
|
)
|
|
51
68
|
|
|
52
69
|
if verdict == True:
|
|
53
70
|
d_asp = {
|
|
54
|
-
"p1_name":
|
|
55
|
-
"p1_abs_pos":
|
|
56
|
-
"p2_name":
|
|
57
|
-
"p2_abs_pos":
|
|
71
|
+
"p1_name": first_active_points_list[first]["name"],
|
|
72
|
+
"p1_abs_pos": first_active_points_list[first]["abs_pos"],
|
|
73
|
+
"p2_name": second_active_points_list[second]["name"],
|
|
74
|
+
"p2_abs_pos": second_active_points_list[second]["abs_pos"],
|
|
58
75
|
"aspect": name,
|
|
59
76
|
"orbit": orbit,
|
|
60
77
|
"aspect_degrees": aspect_degrees,
|
|
61
|
-
"color": color,
|
|
62
78
|
"aid": aid,
|
|
63
79
|
"diff": diff,
|
|
64
|
-
"p1":
|
|
65
|
-
|
|
66
|
-
|
|
80
|
+
"p1": planet_id_decoder(
|
|
81
|
+
self.settings.celestial_points, first_active_points_list[first]["name"]
|
|
82
|
+
),
|
|
83
|
+
"p2": planet_id_decoder(
|
|
84
|
+
self.settings.celestial_points,
|
|
85
|
+
second_active_points_list[second]["name"],
|
|
67
86
|
),
|
|
68
87
|
}
|
|
69
88
|
|
|
@@ -73,13 +92,16 @@ class SynastryAspects(NatalAspects):
|
|
|
73
92
|
|
|
74
93
|
|
|
75
94
|
if __name__ == "__main__":
|
|
76
|
-
|
|
77
|
-
|
|
95
|
+
from kerykeion.utilities import setup_logging
|
|
96
|
+
setup_logging(level="debug")
|
|
97
|
+
|
|
98
|
+
john = AstrologicalSubject("John", 1940, 10, 9, 18, 30, "Liverpool")
|
|
99
|
+
yoko = AstrologicalSubject("Yoko", 1933, 2, 18, 18, 30, "Tokyo")
|
|
78
100
|
|
|
79
101
|
synastry_aspects = SynastryAspects(john, yoko)
|
|
80
102
|
|
|
81
103
|
# All aspects
|
|
82
|
-
print(synastry_aspects.
|
|
104
|
+
print(synastry_aspects.all_aspects)
|
|
83
105
|
|
|
84
106
|
# Relevant aspects
|
|
85
|
-
print(synastry_aspects.
|
|
107
|
+
print(synastry_aspects.relevant_aspects)
|