Skip to content

Problem with 3C rho correction #426

@belasi01

Description

@belasi01

Hi @oceancolorcoder

I can process my pySAS006 data to L2 using Mobley99 and Zhang2017 for rho. I wanted to test the 3C method of Pitarch et al, but I got an error :

Calculating 3C glint correction
Rho_sky: 0.028740 Wind: 5.5 m/s
multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
File "/Users/simonbelanger/miniconda3/envs/hypercp2/lib/python3.11/multiprocessing/pool.py", line 125, in worker
result = (True, func(*args, **kwds))
^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/miniconda3/envs/hypercp2/lib/python3.11/multiprocessing/pool.py", line 48, in mapstar
return list(map(*args))
^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/OneDrive - UQAR/data/MECATINA_2025/python_Scripts/run_MECATINA2025.py", line 224, in worker
run_Command(fp_input_files)
File "/Users/simonbelanger/OneDrive - UQAR/data/MECATINA_2025/python_Scripts/run_MECATINA2025.py", line 200, in run_Command
Command(
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Main.py", line 750, in init
Controller.processSingleLevel(
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/Controller.py", line 750, in processSingleLevel
root = Controller.processL2(root,outFilePath)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/Controller.py", line 463, in processL2
node = ProcessL2.processL2(root,station)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/ProcessL2.py", line 2063, in processL2
if not ProcessL2.stationsEnsemblesReflectance(node, root,station):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/ProcessL2.py", line 1962, in stationsEnsemblesReflectance
if not ProcessL2.ensemblesReflectance(node, sasGroup, referenceGroup, ancGroup,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/ProcessL2.py", line 1480, in ensemblesReflectance
xUNC.update(instrument.ClassBasedL2(node, uncGroup, rhoScalar, rhoVec, rhoUNC, waveSubset, xSlice))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/ProcessInstrumentUncertainties.py", line 520, in ClassBasedL2
rhoUNC = self.interp_common_wvls(np.array(rhoDelta, dtype=float),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/PycharmProjects/HyperCP/HyperCP/Source/ProcessInstrumentUncertainties.py", line 921, in interp_common_wvls
new_y = np.interp(newWaveBands, x, y) #InterpolatedUnivariateSpline(x, y, k=3)(newWavebands)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/miniconda3/envs/hypercp2/lib/python3.11/site-packages/numpy/lib/function_base.py", line 1599, in interp
return interp_func(x, xp, fp, left, right)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ValueError: object of too small depth for desired array
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/Users/simonbelanger/OneDrive - UQAR/data/MECATINA_2025/python_Scripts/run_MECATINA2025.py", line 260, in
pool.map(worker, fpf_input)
File "/Users/simonbelanger/miniconda3/envs/hypercp2/lib/python3.11/multiprocessing/pool.py", line 367, in map
return self._map_async(func, iterable, mapstar, chunksize).get()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/simonbelanger/miniconda3/envs/hypercp2/lib/python3.11/multiprocessing/pool.py", line 774, in get
raise self._value
ValueError: object of too small depth for desired array

Thanks in advance for your help. I can send the data by email if you need it.

Cheers

Simon

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions