S2 product formats

Hi

Following this suggestion, and this comment, I am writing Sentinel 2 products to disk as beam-dimap.

This seems to fail, as I cannot then open the .dim file:

java.lang.IllegalArgumentException: Angle 258,394,241,143.937 is too high.
	at org.geotools.measure.AngleFormat.format(AngleFormat.java:702)
	at org.geotools.measure.AngleFormat.format(AngleFormat.java:939)
	at org.geotools.measure.AngleFormat.format(AngleFormat.java:861)
	at org.geotools.measure.Angle.toString(Angle.java:164)
	at java.text.MessageFormat.subformat(Unknown Source)
	at java.text.MessageFormat.format(Unknown Source)
	at java.text.Format.format(Unknown Source)
	at org.geotools.resources.IndexedResourceBundle.getString(IndexedResourceBundle.java:490)
	at org.geotools.resources.i18n.Errors.format(Errors.java:76)
	at org.geotools.referencing.operation.projection.MapProjection.verifyGeographicRanges(MapProjection.java:500)
	at org.geotools.referencing.operation.projection.MapProjection.access$000(MapProjection.java:86)
	at org.geotools.referencing.operation.projection.MapProjection$Inverse.transform(MapProjection.java:1033)
	at org.geotools.referencing.operation.projection.MapProjection$Inverse.transform(MapProjection.java:1072)
	at org.geotools.referencing.operation.transform.AbstractMathTransform.transform(AbstractMathTransform.java:236)
	at org.geotools.referencing.operation.transform.ConcatenatedTransformDirect.transform(ConcatenatedTransformDirect.java:68)
	at org.geotools.referencing.CRS.transform(CRS.java:1283)
	at org.geotools.referencing.CRS.transform(CRS.java:1349)
	at org.geotools.geometry.jts.ReferencedEnvelope.transform(ReferencedEnvelope.java:631)
	at org.geotools.geometry.jts.ReferencedEnvelope.transform(ReferencedEnvelope.java:586)
	at org.esa.snap.core.datamodel.CrsGeoCoding.detect180MeridianCrossing(CrsGeoCoding.java:291)
	at org.esa.snap.core.datamodel.CrsGeoCoding.<init>(CrsGeoCoding.java:162)
	at org.esa.snap.core.dataio.dimap.DimapProductHelpers.createCrsGeoCoding(DimapProductHelpers.java:507)
	at org.esa.snap.core.dataio.dimap.DimapProductHelpers.createGeoCoding(DimapProductHelpers.java:268)
	at org.esa.snap.core.dataio.dimap.DimapProductReader.initGeoCodings(DimapProductReader.java:164)
	at org.esa.snap.core.dataio.dimap.DimapProductReader.processProduct(DimapProductReader.java:153)
	at org.esa.snap.core.dataio.dimap.DimapProductReader.readProductNodesImpl(DimapProductReader.java:117)
	at org.esa.snap.core.dataio.AbstractProductReader.readProductNodes(AbstractProductReader.java:169)
	at org.esa.snap.core.dataio.ProductIO.readProduct(ProductIO.java:161)
	at org.esa.snap.rcp.actions.file.ReadProductOperation.run(ReadProductOperation.java:51)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
[catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)

What’s going on?

1 Like

Hi,

thank you for reporting. It seems to be the same issue detected some weeks ago: https://senbox.atlassian.net/projects/SIITBX/issues/SIITBX-252?filter=allopenissues

Could you please tell us the original name of the product? Are you able to open it in SNAP GUI before writing it as beam-dimap? What version of SNAP and OS are you using?

Hello

Thanks for your reply.

Product: S2A_USER_PRD_MSIL2A_PDMC_20160329T155612_R094_V20160325T110046_20160325T110046.SAFE

Yes, I can open the product in both SNAP and snappy before saving as BEAM-DIMAP.

I’m running SNAP 5.0 and Win 8.1 Pro