Sen2Cor: "TypeError: Invalid input object: NoneType"

Hello everyone!

I’ve looked on the forum for some kind of solution but I haven’t been lucky to find one that would help me resolving the problem.

This is the error message I get when I prompt the command from Windows cmd.exe:

D:\Xander_C\Documents\Tesi\data\S2A_OPER_PRD_MSIL1C>L2A_Process --resolution 10 --GIP_L2A_AC GIP_L2A_AC S2A_OPER_PRD_MSIL1C_PDMC_20160929T000654_R122_V20150820T100016_20150820T100728.SAFE

Sentinel-2 Level 2A Prototype Processor (Sen2Cor), 2.2.1, created: 2016.04.29 started …
Traceback (most recent call last):
File “C:\Program Files\Anaconda2\Scripts\”, line 9, in
load_entry_point(‘sen2cor==2.2.1’, ‘console_scripts’, ‘L2A_Process’)()
File “C:\Program Files\Anaconda2\lib\site-packages\sen2cor-2.2.1-py2.7.egg\sen2cor\”, line 221, in main
result = config.readPreferences()
File “C:\Program Files\Anaconda2\lib\site-packages\sen2cor-2.2.1-py2.7.egg\sen2cor\”, line 3258, in readPreferences
File “C:\Program Files\Anaconda2\lib\site-packages\sen2cor-2.2.1-py2.7.egg\sen2cor\”, line 161, in export
objectify.deannotate(self._root, xsi_nil=True, cleanup_namespaces=True)
File “lxml.objectify.pyx”, line 1728, in lxml.objectify.deannotate (src\lxml\lxml.objectify.c:24484)
File “cleanup.pxi”, line 49, in lxml.etree.strip_attributes (src\lxml\lxml.etree.c:150012)
File “apihelpers.pxi”, line 63, in lxml.etree._rootNodeOrRaise (src\lxml\lxml.etree.c:15610)
TypeError: Invalid input object: NoneType

Actually the same error is given even if the command used is:

L2A_Process --resolution 10 --GIP_L2A_AC GIP_L2A_AC S2A_OPER_PRD_MSIL1C_PDMC_20160929T000654_R122_V20150820T100016_20150820T100728.SAFE

Has anyone ever got the same errors before?

Thank you,


Hello. Please provide the OS version and the anaconda version that you installed. I can see the Sen2Cor version is 2.2.1, and the error is present using the command, so the SNAP version is not important.

Hi! Thank you for your reply!

I’m working on Windows 10 Build 1607 with Anaconda 4.2.9.
Later I’m testing on CentOS 6.6 with the same Anaconda version and I get another error after few minutes of elaboration (but at least it does something)

But I think it is some problem with the configuration file… Or at least I hope!

~ Alessandro

Had the same issue today, only in my case the process wouldn’t start at all.

I just went into sen2cor download directory, and I ran the install command again: python install
Worked for me!
I am using Ubuntu 14.04 x64, just the Sen2Cor tool, without SNAP.


1 Like

If it happens again, try installing with the older version of Anaconda2 (4.0.0)

Yep, it is still giving the same error on Windows

Sorry, now I see that your problem was with the ozoneContent. Could you please tell me the parameters you used in L2A_GIPP.xml for Aerosol_Type, Mid_Latitude, and Ozone_Content ?

That is the configuration I’m using on both the systems

Aerosol_Type = Auto

Mid_Latitude = Auto

Ozone_Content = 0

That’s it, I had the same problem. Try to specify Aerosol Type and Mid Latitude (doesn’t make much sense, I know).

Hello again,

I’ve tested different configurations on Windows and it still doesn’t even start (but I think I’ll give up on this platform). On the CentOS system it always fails for the “key = columns.get” with any parameters of the Ozone_Content values.

Unfortunatly I can’t change the Anaconda version until the technician is back so I can only wait for now.

Thank you for your support until now,


Hi Alessandro,

Re the windows error: have you tried restarting your computer? I know it’s a stupid question but I had the same issue and after restarting it seems to be fixed (still running so touch wood…)


I think it’s now about the Ozone Content, with me the problem was setting Mid Latitude and Aerosol to AUTO , when you set it like that the above error pops out. Here is my L2A_GIPP.xml (4.1 KB) , working without problems (for now :slight_smile: , because with Sen2Cor you never know).


Tried in conjunction with the new L2A_GIPP.xml provided by @Ognjen but still nothing :<


I’ve tried your configuration on both the systems butunfortunatly the errors are still the same.

~ Alessandro

Hi guys,
whenever I try to run:
L2A_Process --resolution 10 --GIP_L2A_AC GIP_L2A_AC + directory it returns:

Sentinel-2 Level 2A Prototype Processor (Sen2Cor), 2.3.0, created: 2016.11.18 started ...
file does not exist: C:\Users\FaTHER\Documents\sen2cor\cfg\GIP_L2A_AC

I checked the folder and there is the file L2A_GIPP.xml. Why does he call for GIP_L2A_AC file?
Anyone encountered this? Thanks.

please don’t cross-post over various topics.