diff --git a/docs/sphinx/_build/doctrees/borea.utils.check.doctree b/docs/sphinx/_build/doctrees/borea.utils.check.doctree
index 4080608..709e432 100644
Binary files a/docs/sphinx/_build/doctrees/borea.utils.check.doctree and b/docs/sphinx/_build/doctrees/borea.utils.check.doctree differ
diff --git a/docs/sphinx/_build/doctrees/borea.utils.solver.doctree b/docs/sphinx/_build/doctrees/borea.utils.solver.doctree
index 5c60dea..834c298 100644
Binary files a/docs/sphinx/_build/doctrees/borea.utils.solver.doctree and b/docs/sphinx/_build/doctrees/borea.utils.solver.doctree differ
diff --git a/docs/sphinx/_build/doctrees/environment.pickle b/docs/sphinx/_build/doctrees/environment.pickle
index f489c1c..5f7978e 100644
Binary files a/docs/sphinx/_build/doctrees/environment.pickle and b/docs/sphinx/_build/doctrees/environment.pickle differ
diff --git a/docs/sphinx/_build/html/_modules/borea/datastruct/camera.html b/docs/sphinx/_build/html/_modules/borea/datastruct/camera.html
index 23b2e1f..3b07747 100644
--- a/docs/sphinx/_build/html/_modules/borea/datastruct/camera.html
+++ b/docs/sphinx/_build/html/_modules/borea/datastruct/camera.html
@@ -228,6 +228,7 @@
"""
A module for manipulating a digital elevation model.
"""
-from pathlib import Path , PureWindowsPath
import numpy as np
from osgeo import gdal
from scipy import ndimage
from borea.transform_world_image.transform_dtm.world_image_dtm import WorldImageDtm
+from borea.utils.check.check_path import check_path
from borea.utils.singleton.singleton import Singleton
gdal . UseExceptions ()
@@ -327,7 +328,7 @@ Source code for borea.datastruct.dtm
if path_dtm :
gdal . AllRegister ()
self . type_dtm = type_dtm
- self . path_dtm = Path ( PureWindowsPath ( path_dtm ))
+ self . path_dtm = check_path ( path_dtm )
self . img = gdal . Open ( self . path_dtm . as_posix ())
self . rb = self . img . GetRasterBand ( 1 )
self . nodata = self . rb . GetNoDataValue ()
diff --git a/docs/sphinx/_build/html/_modules/borea/datastruct/gcp.html b/docs/sphinx/_build/html/_modules/borea/datastruct/gcp.html
index 416cc8c..bc05285 100644
--- a/docs/sphinx/_build/html/_modules/borea/datastruct/gcp.html
+++ b/docs/sphinx/_build/html/_modules/borea/datastruct/gcp.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/datastruct/shot.html b/docs/sphinx/_build/html/_modules/borea/datastruct/shot.html
index dc1965e..d4da668 100644
--- a/docs/sphinx/_build/html/_modules/borea/datastruct/shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/datastruct/shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/datastruct/workdata.html b/docs/sphinx/_build/html/_modules/borea/datastruct/workdata.html
index 5e565e1..f3ec3b0 100644
--- a/docs/sphinx/_build/html/_modules/borea/datastruct/workdata.html
+++ b/docs/sphinx/_build/html/_modules/borea/datastruct/workdata.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/format/conl.html b/docs/sphinx/_build/html/_modules/borea/format/conl.html
index 7531774..12fb2a9 100644
--- a/docs/sphinx/_build/html/_modules/borea/format/conl.html
+++ b/docs/sphinx/_build/html/_modules/borea/format/conl.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/format/rpc.html b/docs/sphinx/_build/html/_modules/borea/format/rpc.html
index 4ec50f7..d63e49a 100644
--- a/docs/sphinx/_build/html/_modules/borea/format/rpc.html
+++ b/docs/sphinx/_build/html/_modules/borea/format/rpc.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/approx_euclidean_proj.html b/docs/sphinx/_build/html/_modules/borea/geodesy/approx_euclidean_proj.html
index dfa7420..4f51813 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/approx_euclidean_proj.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/approx_euclidean_proj.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/euclidean_proj.html b/docs/sphinx/_build/html/_modules/borea/geodesy/euclidean_proj.html
index 6a2521f..381c9de 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/euclidean_proj.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/euclidean_proj.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/local_euclidean_proj.html b/docs/sphinx/_build/html/_modules/borea/geodesy/local_euclidean_proj.html
index af7b2b6..8293b79 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/local_euclidean_proj.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/local_euclidean_proj.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/proj_engine.html b/docs/sphinx/_build/html/_modules/borea/geodesy/proj_engine.html
index 2ff8f1d..1d221ab 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/proj_engine.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/proj_engine.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/projectionlist/search_proj.html b/docs/sphinx/_build/html/_modules/borea/geodesy/projectionlist/search_proj.html
index c4245ce..bb6d967 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/projectionlist/search_proj.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/projectionlist/search_proj.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/geodesy/transform_geodesy.html b/docs/sphinx/_build/html/_modules/borea/geodesy/transform_geodesy.html
index 14cce1c..a071991 100644
--- a/docs/sphinx/_build/html/_modules/borea/geodesy/transform_geodesy.html
+++ b/docs/sphinx/_build/html/_modules/borea/geodesy/transform_geodesy.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_add_shot.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_add_shot.html
index 9cfc6cd..6831b77 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_add_shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_add_shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp2d.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp2d.html
index 4c48736..55491ad 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp2d.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp2d.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp3d.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp3d.html
index 8a2119d..08fd0a5 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp3d.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_file_gcp3d.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_gen_param.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_gen_param.html
index 103a799..6072cc8 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_gen_param.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_gen_param.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_proj.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_proj.html
index e65ae13..7793b62 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_proj.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_proj.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt2d.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt2d.html
index ba852a7..484fb48 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt2d.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt2d.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt3d.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt3d.html
index 6dc78fd..a3ff52f 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt3d.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_pt3d.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_unit_shot.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_unit_shot.html
index aeaf34e..6473293 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_unit_shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_unit_shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_write.html b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_write.html
index 3caffdc..5fb2d45 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_write.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_add_data/p_write.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_read_opk.html b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_read_opk.html
index 233ffe7..4d1fd32 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_read_opk.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_read_opk.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_con.html b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_con.html
index be119a1..cc2dde8 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_con.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_con.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_opk.html b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_opk.html
index 6b91dc4..4d59e96 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_opk.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_opk.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_rpc.html b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_rpc.html
index d82177f..db111c6 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_rpc.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_format/p_write_rpc.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_control.html b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_control.html
index b911634..0de09cc 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_control.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_control.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_image_world.html b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_image_world.html
index 4bf5b1e..882723e 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_image_world.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_image_world.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_spaceresection.html b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_spaceresection.html
index da4d76a..26f2608 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_spaceresection.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_spaceresection.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_tf_proj_pt.html b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_tf_proj_pt.html
index a3d554b..683d71f 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_tf_proj_pt.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_tf_proj_pt.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_world_image.html b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_world_image.html
index 3f42423..7459651 100644
--- a/docs/sphinx/_build/html/_modules/borea/process/p_func/p_world_image.html
+++ b/docs/sphinx/_build/html/_modules/borea/process/p_func/p_world_image.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/reader/orientation/manage_reader.html b/docs/sphinx/_build/html/_modules/borea/reader/orientation/manage_reader.html
index 0536c87..d647b09 100644
--- a/docs/sphinx/_build/html/_modules/borea/reader/orientation/manage_reader.html
+++ b/docs/sphinx/_build/html/_modules/borea/reader/orientation/manage_reader.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -276,7 +277,7 @@
Source code for borea.reader.orientation.manage_reader Photogrammetry site file reader module.
"""
import importlib
-
from pathlib import Path , PureWindowsPath
+
from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
@@ -295,7 +296,7 @@
Source code for borea.reader.orientation.manage_reader """
# Attention multiple file management orientation
# Attention management of files with the same extension but different formats
-
file = Path ( PureWindowsPath ( file ))
+
file = check_path ( file )
name_work = file . stem
ext = file . suffix [ 1 :]
diff --git a/docs/sphinx/_build/html/_modules/borea/reader/orientation/reader_opk.html b/docs/sphinx/_build/html/_modules/borea/reader/orientation/reader_opk.html
index f0328e6..b9ff9b8 100644
--- a/docs/sphinx/_build/html/_modules/borea/reader/orientation/reader_opk.html
+++ b/docs/sphinx/_build/html/_modules/borea/reader/orientation/reader_opk.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/reader/reader_camera.html b/docs/sphinx/_build/html/_modules/borea/reader/reader_camera.html
index 1dc9302..b7a66cf 100644
--- a/docs/sphinx/_build/html/_modules/borea/reader/reader_camera.html
+++ b/docs/sphinx/_build/html/_modules/borea/reader/reader_camera.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -275,8 +276,9 @@
Source code for borea.reader.reader_camera
"""
Script to read camera file txt or xml.
"""
-from pathlib import Path , PureWindowsPath
+from pathlib import Path
from borea.datastruct.camera import Camera
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
@@ -291,7 +293,7 @@ Source code for borea.reader.reader_camera
work (Worksite): Worksite which needs camera data.
"""
for file in files :
- camera_txt ( Path ( PureWindowsPath ( file )), work )
+ camera_txt ( check_path ( file ), work )
diff --git a/docs/sphinx/_build/html/_modules/borea/reader/reader_point.html b/docs/sphinx/_build/html/_modules/borea/reader/reader_point.html
index 4de8243..eecdbf4 100644
--- a/docs/sphinx/_build/html/_modules/borea/reader/reader_point.html
+++ b/docs/sphinx/_build/html/_modules/borea/reader/reader_point.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -276,9 +277,9 @@
Source code for borea.reader.reader_point
Script to read point (connecting point, gcp2d gcp3d) format
.txt/.mes/.app with data arranged in columns.
"""
-from pathlib import Path , PureWindowsPath
import pandas as pd
import numpy as np
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
from borea.utils.check.check_args_reader_pt import check_header_file
@@ -302,7 +303,7 @@ Source code for borea.reader.reader_point
work . type_z_data = type_z
try :
- with open ( Path ( PureWindowsPath ( path )), 'r' , encoding = "utf-8" ) as file_pts :
+ with open ( check_path ( path ), 'r' , encoding = "utf-8" ) as file_pts :
for pt in file_pts . readlines ():
if pt != ' \n ' and pt [ 0 ] != '#' :
info = pt . split ()
@@ -353,7 +354,7 @@ Source code for borea.reader.reader_point
ttype = []
coor = []
try :
- with open ( Path ( PureWindowsPath ( path )), 'r' , encoding = "utf-8" ) as file_pts :
+ with open ( check_path ( path ), 'r' , encoding = "utf-8" ) as file_pts :
for pt in file_pts . readlines ():
if pt != ' \n ' and pt [ 0 ] != '#' :
info = pt . split ()
diff --git a/docs/sphinx/_build/html/_modules/borea/stat/statistics.html b/docs/sphinx/_build/html/_modules/borea/stat/statistics.html
index 419895c..0179033 100644
--- a/docs/sphinx/_build/html/_modules/borea/stat/statistics.html
+++ b/docs/sphinx/_build/html/_modules/borea/stat/statistics.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -277,8 +278,8 @@
Source code for borea.stat.statistics
"""
import os
import io
-from pathlib import Path , PureWindowsPath
import numpy as np
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
@@ -298,7 +299,7 @@ Source code for borea.stat.statistics
type_point (list): List of type point on which we make the stats.
"""
self . work = work
- self . pathoutput = Path ( PureWindowsPath ( pathoutput ))
+ self . pathoutput = check_path ( pathoutput )
if type_point is None :
self . type_point = []
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_dtm/world_image_dtm.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_dtm/world_image_dtm.html
index 351684a..f901a1a 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_dtm/world_image_dtm.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_dtm/world_image_dtm.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/conversion_coor_shot.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/conversion_coor_shot.html
index 119544a..e8a0364 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/conversion_coor_shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/conversion_coor_shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/image_world_shot.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/image_world_shot.html
index b2355b2..fb57bfa 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/image_world_shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/image_world_shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/world_image_shot.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/world_image_shot.html
index 8cacca3..b7cb613 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/world_image_shot.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_shot/world_image_shot.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_intersection.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_intersection.html
index d32f44e..4780bd8 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_intersection.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_intersection.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_least_square.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_least_square.html
index e8937bd..1426e26 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_least_square.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_least_square.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_work.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_work.html
index 13d2ded..ba619a8 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_work.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/image_world_work.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/space_resection.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/space_resection.html
index 0575cb3..2704dd9 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/space_resection.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/space_resection.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/world_image_work.html b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/world_image_work.html
index 70aefee..b06e11a 100644
--- a/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/world_image_work.html
+++ b/docs/sphinx/_build/html/_modules/borea/transform_world_image/transform_worksite/world_image_work.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_opk.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_opk.html
index 354358f..219ff8a 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_opk.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_opk.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_reader_pt.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_reader_pt.html
index f98380e..4f4aa47 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_reader_pt.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_args_reader_pt.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_array.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_array.html
index 8d3bf21..01682b5 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/check/check_array.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_array.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_header.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_header.html
index 25ddac9..15ce23d 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/check/check_header.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_header.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_order_axe.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_order_axe.html
index 8cb94bb..08124bb 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/check/check_order_axe.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_order_axe.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/check/check_path.html b/docs/sphinx/_build/html/_modules/borea/utils/check/check_path.html
new file mode 100644
index 0000000..a5e9c7a
--- /dev/null
+++ b/docs/sphinx/_build/html/_modules/borea/utils/check/check_path.html
@@ -0,0 +1,341 @@
+
+
+
+
+
+
+
+
borea.utils.check.check_path - Borea 0.2.1 documentation
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Contents
+
+
+
+
+
+
+ Expand
+
+
+
+
+
+ Light mode
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Dark mode
+
+
+
+
+
+
+ Auto light/dark, in light mode
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Auto light/dark, in dark mode
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Hide table of contents sidebar
+
+
+
Skip to content
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Back to top
+
+
+
+
+ Toggle Light / Dark / Auto color theme
+
+
+
+
+
+
+
+ Toggle table of contents sidebar
+
+
+
+
+ Source code for borea.utils.check.check_path
+"""
+Script to check path of data.
+"""
+from pathlib import Path , PureWindowsPath , PurePosixPath
+
+
+
[docs]
+
def check_path ( file : str ) -> Path :
+
"""
+
Check path of data if Posix of Windows path.
+
+
Args:
+
file (str): The path of data.
+
+
Returns:
+
Path: The good path.
+
"""
+
file = Path ( file )
+
name = file . stem
+
+
if "/" in name :
+
return Path ( PurePosixPath ( file ))
+
+
if " \\ " in name :
+
return Path ( PureWindowsPath ( file ))
+
+
return file
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Copyright © 2023, Antoine Cornu et Nicolas Laurain
+
+ Made with
Sphinx and
@pradyunsg 's
+
+
Furo
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/miscellaneous.html b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/miscellaneous.html
index ba3b49d..2773689 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/miscellaneous.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/miscellaneous.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/param_bundle.html b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/param_bundle.html
index b1f6b70..dbe4e1b 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/param_bundle.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/param_bundle.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/sparse.html b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/sparse.html
index 4601240..e7de2b9 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/sparse.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/miscellaneous/sparse.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/singleton/singleton.html b/docs/sphinx/_build/html/_modules/borea/utils/singleton/singleton.html
index 2cc5f0b..3bd008b 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/singleton/singleton.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/singleton/singleton.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/solver/solver.html b/docs/sphinx/_build/html/_modules/borea/utils/solver/solver.html
index 22b0bee..deaf807 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/solver/solver.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/solver/solver.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -280,18 +281,18 @@
Source code for borea.utils.solver.solver
[docs]
-
def npsolve ( matA : np . ndarray , matB : np . ndarray ) -> np . ndarray :
+
def npsolve ( mat_a : np . ndarray , mat_b : np . ndarray ) -> np . ndarray :
"""
Solver used by Borea to resolve Ax = B
Args:
-
matA (np.ndarray): Matrix A
-
matB (np.ndarray): Matrix B
+
mat_a (np.ndarray): Matrix A
+
mat_b (np.ndarray): Matrix B
Returns:
np.ndarray: the result x
"""
-
return np . linalg . lstsq ( matA , matB , rcond = None )[ 0 ]
+ return np . linalg . lstsq ( mat_a , mat_b , rcond = None )[ 0 ]
diff --git a/docs/sphinx/_build/html/_modules/borea/utils/xml/xml.html b/docs/sphinx/_build/html/_modules/borea/utils/xml/xml.html
index 25e0419..d2123d0 100644
--- a/docs/sphinx/_build/html/_modules/borea/utils/xml/xml.html
+++ b/docs/sphinx/_build/html/_modules/borea/utils/xml/xml.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/worksite/worksite.html b/docs/sphinx/_build/html/_modules/borea/worksite/worksite.html
index a9dba84..a80db55 100644
--- a/docs/sphinx/_build/html/_modules/borea/worksite/worksite.html
+++ b/docs/sphinx/_build/html/_modules/borea/worksite/worksite.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/writer/manage_writer.html b/docs/sphinx/_build/html/_modules/borea/writer/manage_writer.html
index 09f233b..88569c6 100644
--- a/docs/sphinx/_build/html/_modules/borea/writer/manage_writer.html
+++ b/docs/sphinx/_build/html/_modules/borea/writer/manage_writer.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
diff --git a/docs/sphinx/_build/html/_modules/borea/writer/writer_con.html b/docs/sphinx/_build/html/_modules/borea/writer/writer_con.html
index 4cd53b8..463d88b 100644
--- a/docs/sphinx/_build/html/_modules/borea/writer/writer_con.html
+++ b/docs/sphinx/_build/html/_modules/borea/writer/writer_con.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -276,7 +277,7 @@
Source code for borea.writer.writer_con
Photogrammetry worksite to writing in rpc.
"""
import os
-from pathlib import Path , PureWindowsPath
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
from borea.geodesy.proj_engine import ProjEngine
from borea.format.conl import Conl
@@ -307,7 +308,7 @@ Source code for borea.writer.writer_con
for name_shot , shot in work . shots . items ():
cam = work . cameras [ shot . name_cam ]
- path_conical = os . path . join ( Path ( PureWindowsPath ( folder_con )), f " { name_shot } .CON" )
+ path_conical = os . path . join ( check_path ( folder_con ), f " { name_shot } .CON" )
Conl ( shot , cam , geoview_proj ) . save_conl ( path_conical )
diff --git a/docs/sphinx/_build/html/_modules/borea/writer/writer_df_to_txt.html b/docs/sphinx/_build/html/_modules/borea/writer/writer_df_to_txt.html
index e5ef698..7dfd2da 100644
--- a/docs/sphinx/_build/html/_modules/borea/writer/writer_df_to_txt.html
+++ b/docs/sphinx/_build/html/_modules/borea/writer/writer_df_to_txt.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -276,8 +277,8 @@
Source code for borea.writer.writer_df_to_txt Photogrammetry worksite to writing dataframe to txt.
"""
import os
-from pathlib import Path , PureWindowsPath
import pandas as pd
+from borea.utils.check.check_path import check_path
@@ -291,7 +292,7 @@
Source code for borea.writer.writer_df_to_txt pathreturn (str): Path to save the file.
df (pd.DataFrame): DataFrame to save.
"""
- path_txt = os . path . join ( Path ( PureWindowsPath ( pathreturn )), f " { name } .txt" )
+ path_txt = os . path . join ( check_path ( pathreturn ), f " { name } .txt" )
name_column = list ( df . columns )
diff --git a/docs/sphinx/_build/html/_modules/borea/writer/writer_opk.html b/docs/sphinx/_build/html/_modules/borea/writer/writer_opk.html
index dd33a4d..68cb49e 100644
--- a/docs/sphinx/_build/html/_modules/borea/writer/writer_opk.html
+++ b/docs/sphinx/_build/html/_modules/borea/writer/writer_opk.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+borea.utils.solver package
borea.utils.xml package
@@ -276,8 +277,8 @@ Source code for borea.writer.writer_opk
Photogrammetry worksite to writing in opk.
"""
import os
-from pathlib import Path , PureWindowsPath
import numpy as np
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
from borea.utils.check.check_args_opk import check_header_file
@@ -300,7 +301,7 @@ Source code for borea.writer.writer_opk
linear alteration.
work (Worksite): The site to be recorded.
"""
- path_opk = os . path . join ( Path ( PureWindowsPath ( path_opk )), f " { name_opk } .opk" )
+ path_opk = os . path . join ( check_path ( path_opk ), f " { name_opk } .opk" )
if args [ "header" ]:
header , type_z = check_header_file ( args [ "header" ])
diff --git a/docs/sphinx/_build/html/_modules/borea/writer/writer_rpc.html b/docs/sphinx/_build/html/_modules/borea/writer/writer_rpc.html
index b36cfc7..834f537 100644
--- a/docs/sphinx/_build/html/_modules/borea/writer/writer_rpc.html
+++ b/docs/sphinx/_build/html/_modules/borea/writer/writer_rpc.html
@@ -228,6 +228,7 @@
borea.utils.check package
borea.utils.miscellaneous package
borea.utils.singleton package
+
borea.utils.solver package
borea.utils.xml package
@@ -276,8 +277,8 @@
Source code for borea.writer.writer_rpc
Photogrammetry worksite to writing in rpc.
"""
import os
-from pathlib import Path , PureWindowsPath
from borea.format.rpc import Rpc
+from borea.utils.check.check_path import check_path
from borea.worksite.worksite import Worksite
from borea.datastruct.dtm import Dtm
@@ -329,9 +330,9 @@ Source code for borea.writer.writer_rpc
for idx , val in enumerate ( rpc . param_rpc [ "SAMP_DEN_COEFF" ]):
list_txt_rpc += [ f "SAMP_DEN_COEFF_ { idx + 1 } : { val } " ]
- path_rpc = os . path . join ( Path ( PureWindowsPath ( folder_rpc )),
+ path_rpc = os . path . join ( check_path ( folder_rpc ),
f " { name_shot } _RPC.TXT" )
- Path ( path_rpc ) . write_text ( " \n " . join ( list_txt_rpc ), encoding = "UTF-8" )
+ check_path ( path_rpc ) . write_text ( " \n " . join ( list_txt_rpc ), encoding = "UTF-8" )
diff --git a/docs/sphinx/_build/html/_modules/index.html b/docs/sphinx/_build/html/_modules/index.html
index 8b7e716..7592294 100644
--- a/docs/sphinx/_build/html/_modules/index.html
+++ b/docs/sphinx/_build/html/_modules/index.html
@@ -323,6 +323,7 @@ All modules for which code is available
borea.utils.check.check_array
borea.utils.check.check_header
borea.utils.check.check_order_axe
+
borea.utils.check.check_path
borea.utils.miscellaneous.miscellaneous
borea.utils.miscellaneous.param_bundle
borea.utils.miscellaneous.sparse
diff --git a/docs/sphinx/_build/html/_sources/borea.utils.check.rst.txt b/docs/sphinx/_build/html/_sources/borea.utils.check.rst.txt
index 88299e4..c95b9e5 100644
--- a/docs/sphinx/_build/html/_sources/borea.utils.check.rst.txt
+++ b/docs/sphinx/_build/html/_sources/borea.utils.check.rst.txt
@@ -44,6 +44,14 @@ borea.utils.check.check\_order\_axe module
:undoc-members:
:show-inheritance:
+borea.utils.check.check\_path module
+------------------------------------
+
+.. automodule:: borea.utils.check.check_path
+ :members:
+ :undoc-members:
+ :show-inheritance:
+
Module contents
---------------
diff --git a/docs/sphinx/_build/html/borea.html b/docs/sphinx/_build/html/borea.html
index 43618c8..40ddf3b 100644
--- a/docs/sphinx/_build/html/borea.html
+++ b/docs/sphinx/_build/html/borea.html
@@ -578,6 +578,7 @@
borea.utils.check.check_header module
borea.utils.check.check_order_axe module
+
borea.utils.check.check_path module
Module contents
diff --git a/docs/sphinx/_build/html/borea.utils.check.html b/docs/sphinx/_build/html/borea.utils.check.html
index 1b9d959..df54df9 100644
--- a/docs/sphinx/_build/html/borea.utils.check.html
+++ b/docs/sphinx/_build/html/borea.utils.check.html
@@ -475,6 +475,27 @@
Submodules