Skip to content
Snippets Groups Projects
Commit a769d5ab authored by Maciej Wielgosz's avatar Maciej Wielgosz
Browse files

updated oracle wrapper local

parent 31f7eed2
No related branches found
No related tags found
No related merge requests found
Dockerfile - set correct oracle wrapper
build.sh
run_oracle_wrapper.py or run_oracle_wrapper_local.py -> set paths
run_oracle_wrapper.py or run_oracle_wrapper_local.py -> pick a right mode (DEBUG or not)
config.yaml -> pick segmentation or instance segmentation
\ No newline at end of file
# This is the the file to be run on the oracle cloud
# Author: Maciej Wielgosz
# THis the oracle wrapper for the Oracle Cloud Infrastructure (OCI) environment and Docker container
import oci
import argparse
import os
import io
import shutil
import yaml
from run import main
DEBUG_MODE = False
def run_oracle_wrapper(path_to_config_file):
# read the config file from config folder
......@@ -16,15 +18,19 @@ def run_oracle_wrapper(path_to_config_file):
config_flow_params = yaml.load(f, Loader=yaml.FullLoader)
# read system environment variables
# input_location = os.environ['OBJ_INPUT_LOCATION']
# output_location = os.environ['OBJ_OUTPUT_LOCATION']
# remap the input and output locations
# input_location = input_location.replace("@axqlz2potslu", "").replace("oci://", "/mnt/")
# output_location = output_location.replace("@axqlz2potslu", "").replace("oci://", "/mnt/")
if DEBUG_MODE:
input_location = "local_folder_in/las_files/"
output_location = "local_folder_out/las_files/"
else:
# get the input and output locations from the environment variables
input_location = os.environ['OBJ_INPUT_LOCATION']
output_location = os.environ['OBJ_OUTPUT_LOCATION']
# remap the input and output locations
input_location = input_location.replace("@axqlz2potslu", "").replace("oci://", "/mnt/")
output_location = output_location.replace("@axqlz2potslu", "").replace("oci://", "/mnt/")
input_location = "local_folder_in/las_files/"
output_location = "local_folder_out/las_files/"
# copy files from input_location to the input folder
shutil.copytree(input_location, config_flow_params['general']['input_folder'])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment