diff --git a/Ai_tottle/ai_tottle_api.py b/Ai_tottle/ai_tottle_api.py index 7e1cb3f..d11fd49 100644 --- a/Ai_tottle/ai_tottle_api.py +++ b/Ai_tottle/ai_tottle_api.py @@ -105,7 +105,7 @@ async def process_handler(request): "http://example.com/img1.jpg", "http://example.com/img2.jpg" ], - "yaml_name": "112.44.103.230", + "yaml_name": "config", "bucket_name": "300bdf2b-a150-406e-be63-d28bd29b409f", "bucket_directory": "2025/seg" "model_path": "deeplabv3plus_best.pth" diff --git a/Ai_tottle/map_cut.py b/Ai_tottle/map_cut.py index 15c7829..674d8a7 100644 --- a/Ai_tottle/map_cut.py +++ b/Ai_tottle/map_cut.py @@ -104,7 +104,7 @@ def generate_tiles_from_tif_cli( print(f"瓦片生成成功,元数据已保存到: {json_path}") # 主处理函数 -async def process_tiling(tif_url: str = None, prj_url: str = None, zoom_levels: str = "1-18", bucket: str = "300",config: str = "112.44.103.230") -> dict: +async def process_tiling(tif_url: str = None, prj_url: str = None, zoom_levels: str = "1-18", bucket: str = "300",config: str = "222.212.85.86") -> dict: # 创建唯一任务ID task_id = str(uuid.uuid4()) temp_dir = tempfile.mkdtemp() diff --git a/Ai_tottle/map_find.py b/Ai_tottle/map_find.py index b1877ca..31c8484 100644 --- a/Ai_tottle/map_find.py +++ b/Ai_tottle/map_find.py @@ -105,7 +105,7 @@ def map_process_images(urls, yaml_name, bucket_name, bucket_directory,uav_model_ if __name__ == '__main__': urls = [ "http://171.221.233.49:9000/300bdf2b-a150-406e-be63-d28bd29b409f/qiepian/data7/data3/15/25807/19269.png"] - yaml_name = "112.44.103.230" + yaml_name = "config" bucket_name = "300bdf2b-a150-406e-be63-d28bd29b409f" bucket_directory = "2025/seg" uav_model_path = "D:/work/AI_Python/Ai_tottle/map/checkpoints/deeplabv3plus_best.pth" diff --git a/Ai_tottle/miniohelp.py b/Ai_tottle/miniohelp.py index d9cd3ed..0d4f11b 100644 --- a/Ai_tottle/miniohelp.py +++ b/Ai_tottle/miniohelp.py @@ -145,14 +145,14 @@ def download_file_url(url: str, save_path: str): if __name__ == '__main__': # 初始化 MinIO 客户端 client = Minio( - endpoint="112.44.103.230:9000", + endpoint="222.212.85.86", access_key="adminjdskfj", secret_key="123456ksldjfal@Y", secure=False ) # 示例:通过完整 URL 下载文件 - full_url = "http://112.44.103.230:9000/300bdf2b-a150-406e-be63-d28bd29b409f/media/86961d3a-8790-4bc0-bfc6-dc45a8e4b9bd/DJI_202504291707_001_86961d3a-8790-4bc0-bfc6-dc45a8e4b9bd/DJI_20250429170933_0001_V.jpeg" + full_url = "http://222.212.85.86:9000/300bdf2b-a150-406e-be63-d28bd29b409f/media/86961d3a-8790-4bc0-bfc6-dc45a8e4b9bd/DJI_202504291707_001_86961d3a-8790-4bc0-bfc6-dc45a8e4b9bd/DJI_20250429170933_0001_V.jpeg" bucket_name, object_name = parse_minio_url(full_url) downFile(client, object_name, bucket_name) diff --git a/Ai_tottle/sent_data.py b/Ai_tottle/sent_data.py index 30a3e93..c30bb54 100644 --- a/Ai_tottle/sent_data.py +++ b/Ai_tottle/sent_data.py @@ -203,7 +203,7 @@ def sql_connect(target_id, endpoint, port, dbname, user, password): if conn: conn.close() ################################################################# 坐从 MinIO 获取 JSON 对象内容 ################################################## -def get_minio_json(bucket_name, object_path, yaml_name='112.44.103.230'): +def get_minio_json(bucket_name, object_path, yaml_name='config'): """ 从 MinIO 获取指定对象并解析为 JSON """ diff --git a/Ai_tottle/yolo_train.py b/Ai_tottle/yolo_train.py index 17b4a96..0ea5eb7 100644 --- a/Ai_tottle/yolo_train.py +++ b/Ai_tottle/yolo_train.py @@ -354,7 +354,7 @@ def auto_train( if __name__ == '__main__': auto_train( - db_host='112.44.103.230', + db_host='222.212.85.86', db_database='your_database_name', db_user='postgres', db_password='postgres',