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 - jnb

Pages: [1]
General / Mask defocus area function is broken
« on: January 12, 2022, 07:35:42 PM »

The Mask defocus area function seems to be broken, as well as the Depth threshold one.
The mask seems to be correctly generated during the calculation (and is seen on screen during 1s) but at the end of calculation it only applies to the whole mesh (defocus areas are not masked)

Does anyone else have the same problem?


Feature Requests / Add distance/gsd option to defocus mask generation
« on: February 23, 2021, 05:16:12 PM »

The defocus mask is a great addition to the 1.7 version, but I think there is still room for improvement. When dealing with close-range photogrammetry, some areas in the background could indeed still be in focus but lacking resolution in comparaison with the foreground, leading to visible differences in the orthomosaic. Adding a max distance and/or min gsd option on top of the defocus mask generation would be great in those cases.

Besides, could you detail how the defocus threshold works ? In some cases it seems to operate improperly, leading to in focus areas to be masked whereas out of focus ones are not.


General / Assign images window keeps getting biger and biger
« on: December 22, 2020, 06:00:33 PM »

I noticed some time ago a minor ui bug : when editing an orthoimage using the draw patch tool, the assign images window keeps getting biger and biger every time it is used. It therefore needs to be resized manually every time.

Not a big deal but a fix in the next version would be much appreciated because it's getting really annoying and time consuming when making a lot of ortho edit.

Thank you


I need to move and resize the region according to specific coordinates, but after the application of a rotation matrix to the chunk.

So first, I apply the rotation matrix (see
Code: [Select]
chunk.transform.matrix = S * T
Then I use this script given by Alexey. The Metashape.vector values are picked in the new system (once the rotation matrix applied)
Code: [Select]
import Metashape

side_length = 0.97 #set value here
chunk =
T = chunk.transform.matrix = T.inv().mulp(Metashape.Vector([0.025, -0.1325, -1.0562]))
chunk.region.size = Metashape.Vector([side_length, side_length, side_length]) / chunk.transform.matrix.scale()
chunk.region.rot = T.rotation().t()

print("script finished.")

Unfortunately, this is not working as the region is not in the right place (wrong center), but I don't understand why.
If I use the same script with values for Metashape.vector coming from the original coordinates system and before the application of the rotation matrix, it is working as intended.

Any insights ?
Thank  you !

Python and Java API / [SOLVED] Apply transformation matrix to a chunk
« on: April 03, 2020, 10:17:10 PM »

I'm trying to apply a transformation matrix to a chunk in python, but I am struggling. 
My workflow for now :

- export a scaled model (local coordinates)
- open it in another software to give it correct orientation
- grab the corresponding matrix and apply it in Metashape

Exemple : 

Code: [Select]
import Metashape
doc =
chunk = doc.chunk
S = Metashape.Matrix().Diag([1, 1, 1, 1])

T = Metashape.Matrix([[0.9997743489568586, -0.0211954660930352, -0.0014154098306438, -13.4365763350189269],
                      [0.0000000000000000, -0.0666304947728083, 0.9977777193174494, 851.1973959656927491],
                      [-0.0212426732755011, -0.9975525697342621, -0.0666154595321578, -1634.9351050186285192],
                      [0.0000000000000000, 0.0000000000000000, 0.0000000000000000, 1.0000000000000000 ]])

chunk.transform.matrix = S * T.inv()

The model is indeed moving, but not correctly. The scale is also wrong (I have to hit update in Reference pane to get it right). So what I am doing wrong here ?
Thank you for your help !

Edit : ok, it seems I don't need to use the inverse matrix, chunk.transform.matrix = S * T is giving good results.

General / Import transformation matrix from CloudCompare
« on: December 10, 2019, 09:19:00 PM »

I am looking for a way to import a transformation matrix from CloudCompare (or Geomagic / 3dReshaper) into Metashape for an entire chunk.

Somebody have an idea ?

Thank you

General / Shapes missing on orthomosaic
« on: November 28, 2019, 08:14:41 PM »

I still have issues with the shapes.
I made several orthomosaics within the same project, with different projection planes. I drew shapes on the first one, then on the second one with a different projection plane.
Now, when I go back to the first one, the shapes are no longer in the good projection. Making a new shape or actualising the orthomosaic makes no difference.  Worse, I now have lost the shapes on the second one as well.

It is really confusing since I don't get the logic behind it. Basically, I just lost a huge part of my work.

Thank you for your help.


Working lately on a drone acquisition, I have been stroke by the poor quality of dense cloud noise filtering. I eventually found a topic talking about the same issue :

The last post from Dieter give me the answer :

I had the same problems and was amazed at the poor quality of the point cloud in the latest version. Starting with one of the last versions, the dense_cloud_max_neighbors parameter was set to 100 by default.

Experience has shown that this value was too low for me. Especially with objects that were photographed against the sky, extreme deviations formed.

I set this value to -1 and the calculation time was much longer. Now the point clouds are in the quality of the past again.

I hope I could help.


The default number of depth maps used for the dense cloud filtering stage have indeed been changed  - in June if I am not mistaken - shifting from no limit to 100, without any mention in the change log. To get back to the previous behaviour, you now must use the well known tweak main/dense_cloud_max_neighbors and set it to -1.

This is a major issue for me, as this undocumented change vastly impact the quality of dense cloud on at least some kind of projects. It would have saved me a lot of time and headaches if I have been aware of this change. I understand that this new threshold probably works in most cases but a change so sensitive should have been clearly explained.

You can find attached exemples of how the number of depth maps used impacts this project (default 100, 350 and 850) and the position of the cameras (heavy overlap)

It would be great if in the futur this kind of changes could be more documented.


General / Unwanted dense cloud or mesh cuttings at export (solved)
« on: November 22, 2019, 03:33:13 PM »

On some projects I have unwanted random cuttings when exporting dense cloud or mesh. (v 1.5.5)
Any idea of what could cause this issue ?

Thank you for your help.

Edit : OK I found it. The issue was caused by shapes (boundaries) drawn on the orthomosaic. This shapes impact also the dense cloud and model.

General / Export import Shapes on orthomosaic
« on: November 15, 2019, 07:59:52 PM »

I'm working on a duplicated project and I need to export shapes drawn on an orthomosaic of a wall from the source project and import them into the copy, on the same orthomosaic generated with the same projection plane (3 markers).

Unfortunately, I can't find a way to do it. I think the issue is related to the coordinates system, so I tried to remove the shape layer in both projects and draw the shapes again, with no success.

The chunk is in EPSG 3944 and the orthomosaic and shapes in EPSG 4964

Thank you for your help

Edit: tried to solved my problem using othomosaic import in Metashape 1.6 but didn't work either, apparently EPSG 4964 is not present.

General / Estimation of orthomosaic resolution for imported dense cloud
« on: September 16, 2019, 06:27:14 PM »

I noticed a difference in the orthomosaic resolution estimation between original and imported dense cloud. I only exported the dense cloud generated by Metashape for cleaning purposes on another software and then imported it again in the same project (in ply).

Is there a way to preserve the original resolution estimation ?

Thank you

Bug Reports / Inconsistant window size
« on: June 11, 2019, 09:13:41 PM »

I noticed some time ago a minor ui issue, but still quite annoying a least for me : when editing an ortho using the draw patch tool, the assign images window don't keep the same size and emplacement from a modification to another. It therefore needs to be resize manually every time, especially since it is often beyond the limits of the screen.

Not a big deal but a fix would be much welcome !



Working on a small project, the new mesh generation method has failed two times, stuck on an "Initializing histogram" step. I had to killed Metashape for the whole application was unresponsive (hit the pause button did nothing).
On the first attempt I waited 6 hours, not so much on the second one (about one hour).

You can find the console log attached, as well as a report from nvidia configuration panel.

Thank you for your help.

Python and Java API / Select cameras by extension
« on: November 08, 2018, 02:23:10 PM »

I am working with both dng and tiff cameras in the same project and I would like to select only tiff in Metashape.
Is there a way to do it in python ?

Thank you !

Pages: [1]