Skip to content

data fitting issue #2 #40

Description

@elNava

Hi,

I am having the same error detailed in issue #9. In that case they mention that the filter curve was the problem, but I am using NIRCam filters taken directly from SVO. I am following the steps in the notebooks, this is my input:

[[0.0, 9.9e+100],
 [33.539945030185606, 1.3178399224148853],
 [77.90387252133127, 1.41562451327364],
 [151.94228944830488, 1.3753196635696123],
 [330.4698020919672, 1.5488078001448062],
 [578.144563222296, 1.6778350311376689],
 [751.0610971956924, 2.94762245193689],
 [892.349345751542, 2.2701580967575326]]

And the error:

Bagpipes: fitting object 1420


Completed in 0.1 seconds.

---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
<ipython-input-16-eaec54d81345> in <module>
      1 fit = pipes.fit(galaxy, fit_instructions)
----> 2 fit.fit()

~/.local/lib/python3.8/site-packages/bagpipes/fitting/fit.py in fit(self, verbose, n_live, use_MPI)
    134 
    135             # Load MultiNest outputs and save basic quantities to file.
--> 136             samples2d = np.loadtxt(self.fname + "post_equal_weights.dat")
    137             lnz_line = open(self.fname + "stats.dat").readline().split()
    138 

/opt/anaconda3/lib/python3.8/site-packages/numpy/lib/npyio.py in loadtxt(fname, dtype, comments, delimiter, converters, skiprows, usecols, unpack, ndmin, encoding, max_rows)
   1137         # converting the data
   1138         X = None
-> 1139         for x in read_data(_loadtxt_chunksize):
   1140             if X is None:
   1141                 X = np.array(x, dtype)

/opt/anaconda3/lib/python3.8/site-packages/numpy/lib/npyio.py in read_data(chunk_size)
   1065 
   1066             # Convert each value according to its column and store
-> 1067             items = [conv(val) for (conv, val) in zip(converters, vals)]
   1068 
   1069             # Then pack it according to the dtype's nesting

/opt/anaconda3/lib/python3.8/site-packages/numpy/lib/npyio.py in <listcomp>(.0)
   1065 
   1066             # Convert each value according to its column and store
-> 1067             items = [conv(val) for (conv, val) in zip(converters, vals)]
   1068 
   1069             # Then pack it according to the dtype's nesting

/opt/anaconda3/lib/python3.8/site-packages/numpy/lib/npyio.py in floatconv(x)
    761         if '0x' in x:
    762             return float.fromhex(x)
--> 763         return float(x)
    764 
    765     typ = dtype.type

ValueError: could not convert string to float: '-0.999000000000000022+100'

Which is pretty similar to the issue previous mentioned. I already checked that the SVO filters are in Angstrom, I do not know what else can I check.

Thanks in advance.
Cheers,
Benjamin

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions