[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

I can not load network files



Dear PDP++ developper,

I'm trying to use PDP++, and I have a trouble.

I'm trying to save and load a network status, but the system can not
load the .net file correctly. 
The phenomena is as follows (in css scripts):

    (1) make and save a network using bp++.  
        (here, I made a simple 3-layer 2-3-3 network.)

    	.projects->New(1) ;
	.projects[0].networks->New(1, Network);
	.projects[0].networks[0].layers->New(3, Layer);
	{ Layer* ths = .projects[0].networks[0].layers[0];
	ths->n_units = "2";
	}
	{ Layer* ths = .projects[0].networks[0].layers[1];
	ths->n_units = "3";
	}
	{ Layer* ths = .projects[0].networks[0].layers[2];
	ths->n_units = "3";
	}
	.projects[0].networks[0].layers[1].projections.New(1);
	.projects[0].networks[0].layers[1].projections[0].from_type = Projection::CUSTOM;
	.projects[0].networks[0].layers[1].projections[0].from = .projects[0].networks[0]\
	.layers[0];
	.projects[0].networks[0].layers[2].projections.New(1);
	.projects[0].networks[0].layers[2].projections[0].from_type = Projection::CUSTOM;
	.projects[0].networks[0].layers[2].projections[0].from = .projects[0].networks[0]\
	.layers[1];
	.projects[0].networks[0].Build();
	.projects[0].networks[0].Connect();
	.projects[0].networks[0].views[0].SelectVar("r.wt");
	.projects[0].networks[0].views[0].SelectVar("act");
	.projects[0].networks[0].SaveAs("gen2.net") ;

    (2) load a network.

    	.projects->New(1) ;
	.projects[0].networks->New(1, Network);
	.projects[0].networks[0].Load("gen2.net") ;

Then, a NetView window comes up.  

I checked "s.wt" and selected a unit.  Then the system show a weight
value connected from the unit.  (This is a collect action.)  But, when
I checked "r.wt", the system does not shows the weight value.  (Units
boxes are grey (means 0.0))

Moreover, when I tried to "connect all", the system core-dumped with
the following message.

    bp++> PDP++ saving recover file(s) and exiting from signal: segmentation violation
    Segmentation fault

My operation is wrong?

--Itsuki