Forum

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - freetec1

Pages: [1]
1
Bug Reports / Generate Ortho - Big Tiff Error
« on: May 09, 2022, 03:37:43 PM »
Hello,

i am getting an error when exporting an orthomosaic of an large dataset. I build up a pipeline for the whole process. The part which fails is the following:
Code: [Select]
tasks = []

    task = Metashape.Tasks.ExportRaster()
    task.path = str(Path(*maps_path.parts[3:]).joinpath('dem.tif'))
    task.source_data = Metashape.ElevationData
    task.save_world = True
    tasks.append(task)

    task = Metashape.Tasks.ExportRaster()
    task.path = str(Path(*maps_path.parts[3:]).joinpath('orthomosaic.tif'))
    task.source_data = Metashape.OrthomosaicData
    task.raster_transform = Metashape.RasterTransformType.RasterTransformNone
    task.save_world = True
    task.image_compression = Metashape.ImageCompression.TiffCompressionNone
    task.image_compression.jpeg_quality = 99
    task.image_compression.tiff_big = True
    task.image_compression.tiff_overviews = True
    task.image_compression.tiff_tiled = True
    task.save_alpha = True
    tasks.append(task)

    network_tasks = []
    for task in tasks:
        if task.target == Metashape.Tasks.DocumentTarget:
            network_tasks.append(task.toNetworkTask(_doc))
        else:
            network_tasks.append(task.toNetworkTask(_chunk))

    client = Metashape.NetworkClient()
    client.connect(settings.SERVER_IP)
    batch_id = client.createBatch(project_path, network_tasks)
    client.setBatchPaused(batch_id, False)

Up till around 3000 images everything works fine, but on a project with more than 3000 images it fails on the exporting part of the orthomosaic with the error:

ExportRaster: TIFFWriteTile: unexpected error:...

libtiff error: Maximum TIFF file size exceeded
libtiff error: Maximum TIFF file size exceeded

Is there some way of fixing this with different settings while exporting the orthomosaic? Because on manuel exporting the moasic with the same settings works fine.

Kind regards

Moritz

2
Python and Java API / Metashape on AWS EC2 and S3
« on: February 22, 2022, 07:34:46 PM »
Hello,

i am currently working on implementing Metashape on AWS EC2 and process the data via API. My pipeline is running on my own Server without a problem but i am in need for faster processing and thus I want to move everything in the Cloud.

The Images are on S3 and are mounted via S3FS as a local volume. The project is stored in S3 as well. Storing the project localy works fine, but not when storing it directly in S3.

The pipeline is running in general but there seems to be a problem when reloading the previously stored pointcloud.
Code: [Select]
LoadProject: path = /mnt/photogrammetry_output/Testdatensatz/Testdatensatz.psx
loaded project in 0.042141 sec
Error: Bad local file header signature
OSError: Can't load projections: /mnt/photogrammetry_output/Testdatensatz/Testdatensatz.files/0/0/point_cloud.3/point_cloud.zip

I tried to unzip the "point_cloud.zip" but got the same error with the bad header signatur. As it seems Metashape has a problem when writing zip-files on S3 and reopening them later. Is this a problem related to Metashape or S3? Has somebody tried something simmilar or can give me a hint to solve this problem?

Kind Regards

Moritz



Pages: [1]