Print

Print


The script:
For fingerprint test:
        images=io.read('../../7_18.traj',index='0:2')
        calc = Amp(descriptor=Gaussian(cutoff=10.0),
                   model=NeuralNetwork(hiddenlayers=(5,5)),
                   dblabel='7_18_v1',
                   label='7_18_v1',
                   cores=16)
        calc.model.lossfunction = LossFunction(
                force_coefficient=0.,
                convergence={'energy_rmse': 1.0,
                              'energy_maxresid': 1.0,
                             'force_rmse': None})
        calc.train(images=images )
        fpplot = FingerprintPlot(calc)
        fpplot(images)

For nodeplot I just changed the last two lines to:
nodeplot = NodePlot(calc)
nodeplot.plot(images, filename='node_info.pdf')

I am wondering could the this error related to the images?

On Mon, Jul 31, 2017 at 10:47 AM, Chen, Xi <[log in to unmask]> wrote:

> Yes. That's where I got my initial try. But, When I change the descriptor
> for the different element, the amp does not start to train.
> For example,  I keep the descriptor for 'H' unchanged as default and
> delete some vector for 'C', after the amp interprete the fingerprints it
> hang there,
> and the error file, it shows:
>
>  Step                Time   Loss (SSD)   EnergyRMSE     MaxResid
> ===== =================== ============ ============ ============
> Traceback (most recent call last):
>   File "/gpfs/runtime/opt/python/2.7.3/lib/python2.7/runpy.py", line 162,
> in _run_module_as_main
>     "__main__", fname, loader, pkg_name)
>   File "/gpfs/runtime/opt/python/2.7.3/lib/python2.7/runpy.py", line 72,
> in _run_code
>     exec code in run_globals
>   File "/gpfs_home/xc13/amp/amp/model/__main__.py", line 113, in <module>
>     lossprime=lossprime)
>   File "/users/xc13/amp/amp/model/__init__.py", line 517, in get_loss
>     self._send_data_to_fortran()
>   File "/users/xc13/amp/amp/model/__init__.py", line 475, in
> _send_data_to_fortran
>     self.d)
>   File "/users/xc13/amp/amp/model/__init__.py", line 1083, in
> send_data_to_fortran
>     _fmodules.fingerprint_props.raveled_fingerprints =
> raveled_fingerprints
> ValueError: setting an array element with a sequence.
>
> On Mon, Jul 31, 2017 at 10:25 AM, El Khatib Rodriguez, Muammar <
> [log in to unmask]> wrote:
>
>> On Mon, Jul 31, 2017 at 9:56 AM, Chen, Xi <[log in to unmask]> wrote:
>> > Hello all,
>> >
>> > I am using Amp Gaussian training for a potential surface for a gas phase
>> > combination reaction (with 'C' and 'H' two elements).
>> > However, when I try to test different parameters in the gaussian
>> descriptor
>> > and visualize, I came through some problems.
>> >
>> > 1. For some reason, I can only plot the node information ('NodePlot'
>> > fucntion)  for 'H' element, when the code start to plot "C" element, it
>> > always gave me the following error while calling 'violinplot' function:
>> > ------------------------------------------------
>> >   File
>> > "/gpfs/runtime/opt/python/2.7.3/lib/python2.7/site-packages/
>> numpy/linalg/linalg.py",
>> > line 90, in _raise_linalgerror_singular
>> >     raise LinAlgError("Singular matrix")
>> > numpy.linalg.linalg.LinAlgError: Singular matrix
>> > --------------------------------------------------
>> > I also came through the same problem when I using the 'FingerprintPlot'
>> > function. Tried less images (using 2 images), got the same error.
>> > I am wondering have you ever came through this problem and know why this
>> > happens and fix it?
>> >
>> > 2. Gaussian descriptor can be specified by:
>> > calc = Amp(descriptor = Gaussian(Gs = Gs)).(Gs is the dictionary)
>> >
>> > For the customized Gs, could we have a different number of Gaussian
>> feature
>> > subvectors for different elements? More broadly, I am wondering is
>> there any
>> > rules that I should stick to when I manipulate the descriptor?
>> >
>>
>> I haven't stumbled upon the problem you described on 1. But, regarding
>> your second question, you may take a look at this page in Amp's
>> documentation: http://amp.readthedocs.io/en/latest/gaussian.html.
>> There you will find an example on how you may add more elements to
>> your fingerprint vectors.
>>
>> Best,
>>
>> --
>> Muammar W El Khatib Rodriguez
>> Postdoctoral Research Associate
>> Brown University School of Engineering
>> 184 Hope Street
>> Providence, RI, 02912, USA
>> http://brown.edu/go/catalyst
>>
>
>
>
> --
> Xi CHEN
> Graduate Student
> Department of Chemistry
> Brown University
> Providence
>
>


-- 
Xi CHEN
Graduate Student
Department of Chemistry
Brown University
Providence