maps4fs 2.9.1__py3-none-any.whl → 2.9.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 maps4fs might be problematic. Click here for more details.

@@ -1,6 +1,5 @@
1
1
  """Base class for all components that primarily used to work with meshes."""
2
2
 
3
- import logging
4
3
  import os
5
4
  import shutil
6
5
  import xml.etree.ElementTree as ET
@@ -16,8 +15,6 @@ from tqdm import tqdm
16
15
  from maps4fs.generator.component.base.component import Component
17
16
  from maps4fs.generator.settings import Parameters
18
17
 
19
- logger = logging.getLogger("maps4fs")
20
-
21
18
 
22
19
  class MeshComponent(Component):
23
20
  """Base class for all components that primarily used to work with meshes."""
@@ -607,18 +604,10 @@ class MeshComponent(Component):
607
604
  [f"{n[0]:.6f} {n[1]:.6f} {n[2]:.6f}" for n in mesh.vertex_normals]
608
605
  )
609
606
 
610
- if normal_strings is None:
611
- logger.warning("Normals are missing despite has_normals being True. Can't write i3d.")
612
- return
613
-
614
607
  uv_strings = None
615
608
  if has_uv:
616
609
  uv_strings = np.array([f"{uv[0]:.6f} {uv[1]:.6f}" for uv in mesh.visual.uv])
617
610
 
618
- if uv_strings is None:
619
- logger.warning("UV coordinates are missing despite has_uv being True. Can't write i3d.")
620
- return
621
-
622
611
  # Batch process vertices for memory efficiency
623
612
  batch_size = 2000
624
613
  vertex_elements = []
@@ -634,10 +623,10 @@ class MeshComponent(Component):
634
623
  v_el.set("p", pos_strings[idx])
635
624
 
636
625
  if has_normals:
637
- v_el.set("n", normal_strings[idx])
626
+ v_el.set("n", normal_strings[idx]) # type: ignore
638
627
 
639
628
  if has_uv:
640
- v_el.set("t0", uv_strings[idx])
629
+ v_el.set("t0", uv_strings[idx]) # type: ignore
641
630
 
642
631
  batch_elements.append(v_el)
643
632
 
@@ -103,7 +103,7 @@ def monitor_performance(func: Callable) -> Callable:
103
103
  try:
104
104
  if session_name and time_taken > 0.001 and class_name:
105
105
  PerformanceMonitor().add_record(session_name, class_name, function_name, time_taken)
106
- logger.info(
106
+ logger.debug(
107
107
  "[PERFORMANCE] %s | %s | %s | %s",
108
108
  session_name,
109
109
  class_name,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: maps4fs
3
- Version: 2.9.1
3
+ Version: 2.9.2
4
4
  Summary: Generate map templates for Farming Simulator from real places.
5
5
  Author-email: iwatkot <iwatkot@gmail.com>
6
6
  License: GNU Affero General Public License v3.0
@@ -4,7 +4,7 @@ maps4fs/generator/__init__.py,sha256=zZMLEkGzb4z0xql650gOtGSvcgX58DnJ2yN3vC2daRk
4
4
  maps4fs/generator/config.py,sha256=dHJLBt-Ua5rMMvUujAa3cuPSYvDA7tgfY7Z8tpvT_zo,7176
5
5
  maps4fs/generator/game.py,sha256=_LNiH__7FeSGsPKsuvAGiktt5GcJQVqcQYtsFZNWGyM,16106
6
6
  maps4fs/generator/map.py,sha256=ak74FNSDQXPqaB0gOaZqVo8Sy0fvf_3iXHg6FJkHPpA,15888
7
- maps4fs/generator/monitor.py,sha256=IqNZ6vLlw3vS1dHQ3RPFcGHkKwRfPOPVFy2IR2-wWsE,3523
7
+ maps4fs/generator/monitor.py,sha256=Yrc7rClpmJK53SRzrOYZNBlwJmb5l6TkW-laFbyBEno,3524
8
8
  maps4fs/generator/qgis.py,sha256=Es8hLuqN_KH8lDfnJE6He2rWYbAKJ3RGPn-o87S6CPI,6116
9
9
  maps4fs/generator/settings.py,sha256=_QJL4ikQYLFOIB1zWqXjYvyLfoh3cr2RYb2IzsunMJg,13405
10
10
  maps4fs/generator/statistics.py,sha256=ol0MTiehcCbQFfyYA7cKU-M4_cjiLCktnGbid4GYABU,2641
@@ -21,10 +21,10 @@ maps4fs/generator/component/texture.py,sha256=FF2x6F2d5MRD3mls_m7z0JpnfmQVyoUkTh
21
21
  maps4fs/generator/component/base/__init__.py,sha256=zZMLEkGzb4z0xql650gOtGSvcgX58DnJ2yN3vC2daRk,43
22
22
  maps4fs/generator/component/base/component.py,sha256=-7H3donrH19f0_rivNyI3fgLsiZkntXfGywEx4tOnM4,23924
23
23
  maps4fs/generator/component/base/component_image.py,sha256=GXFkEFARNRkWkDiGSjvU4WX6f_8s6R1t2ZYqZflv1jk,9626
24
- maps4fs/generator/component/base/component_mesh.py,sha256=UgtycniJ1anN81R9188D9xewGOFR22nA2TW9mmBGZlU,25878
24
+ maps4fs/generator/component/base/component_mesh.py,sha256=2wGe_-wAZVRljMKzzVJ8jdzIETWg7LjxGj8A3inH5eI,25550
25
25
  maps4fs/generator/component/base/component_xml.py,sha256=MT-VhU2dEckLFxAgmxg6V3gnv11di_94Qq6atfpOLdc,5342
26
- maps4fs-2.9.1.dist-info/licenses/LICENSE.md,sha256=Ptw8AkqJ60c4tRts6yuqGP_8B0dxwOGmJsp6YJ8dKqM,34328
27
- maps4fs-2.9.1.dist-info/METADATA,sha256=sHHN63IF4C9aZplKg50vjhx5jkSwIhI8c49vPeJeGF4,10042
28
- maps4fs-2.9.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
29
- maps4fs-2.9.1.dist-info/top_level.txt,sha256=Ue9DSRlejRQRCaJueB0uLcKrWwsEq9zezfv5dI5mV1M,8
30
- maps4fs-2.9.1.dist-info/RECORD,,
26
+ maps4fs-2.9.2.dist-info/licenses/LICENSE.md,sha256=Ptw8AkqJ60c4tRts6yuqGP_8B0dxwOGmJsp6YJ8dKqM,34328
27
+ maps4fs-2.9.2.dist-info/METADATA,sha256=QimxrdKs_sIJZ9jECZcyFWjva_4-w5iBOm4HZVupXQ4,10042
28
+ maps4fs-2.9.2.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
29
+ maps4fs-2.9.2.dist-info/top_level.txt,sha256=Ue9DSRlejRQRCaJueB0uLcKrWwsEq9zezfv5dI5mV1M,8
30
+ maps4fs-2.9.2.dist-info/RECORD,,