OpenSfM georeferencing, Dockerfile entrypoint change

pull/997/head
Piero Toffanin 2019-06-19 21:43:34 -04:00
rodzic e3bbfecc04
commit 506b231ac9
5 zmienionych plików z 6 dodań i 16 usunięć

Wyświetl plik

@ -129,5 +129,5 @@ RUN rm -rf \
/code/SuperBuild/src/pdal
# Entry point
ENTRYPOINT ["python", "/code/run.py", "code"]
ENTRYPOINT ["python", "/code/run.py"]

Wyświetl plik

@ -59,6 +59,8 @@ def config():
parser.add_argument('name',
metavar='<project name>',
type=alphanumeric_string,
default='code',
nargs='?',
help='Name of Project (i.e subdirectory of projects folder)')
parser.add_argument('--resize-to',

Wyświetl plik

@ -124,6 +124,7 @@ class OSFMContext:
if gcp_path:
config.append("bundle_use_gcp: yes")
config.append("bundle_use_gps: no")
io.copy(gcp_path, self.path("gcp_list.txt"))
config = config + append_config

Wyświetl plik

@ -136,5 +136,5 @@ RUN rm -rf \
/code/SuperBuild/src/pdal
# Entry point
ENTRYPOINT ["python", "/code/run.py", "code"]
ENTRYPOINT ["python", "/code/run.py"]

Wyświetl plik

@ -80,20 +80,7 @@ class ODMGeoreferencingStage(types.ODM_Stage):
else:
kwargs['pc_params'] = ''
# Check to see if the GCP file exists
if not self.params.get('use_exif') and (self.params.get('gcp_file') or tree.odm_georeferencing_gcp):
log.ODM_INFO('Found %s' % gcpfile)
try:
system.run('{bin}/odm_georef -bundleFile {bundle} -imagesPath {imgs} -imagesListPath {imgs_list} '
'-inputFile {model} -outputFile {model_geo} '
'{pc_params} {verbose} '
'-logFile {log} -outputTransformFile {transform_file} -georefFileOutputPath {geo_sys} -gcpFile {gcp} '
'-outputCoordFile {coords}'.format(**kwargs))
except Exception:
log.ODM_EXCEPTION('Georeferencing failed. ')
exit(1)
elif io.file_exists(tree.opensfm_transformation) and io.file_exists(tree.odm_georeferencing_coords):
if io.file_exists(tree.opensfm_transformation) and io.file_exists(tree.odm_georeferencing_coords):
log.ODM_INFO('Running georeferencing with OpenSfM transformation matrix')
system.run('{bin}/odm_georef -bundleFile {bundle} -inputTransformFile {input_trans_file} -inputCoordFile {coords} '
'-inputFile {model} -outputFile {model_geo} '