-
Notifications
You must be signed in to change notification settings - Fork 0
/
HSolveActiveSetup.cpp
675 lines (576 loc) · 21.2 KB
/
HSolveActiveSetup.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
/**********************************************************************
** This program is part of 'MOOSE', the
** Messaging Object Oriented Simulation Environment.
** copyright (C) 2003-2007 Upinder S. Bhalla, Niraj Dudani and NCBS
** It is made available under the terms of the
** GNU Lesser General Public License version 2.1
** See the file COPYING.LIB for the full notice.
**********************************************************************/
#include "HSolveActive.h"
//////////////////////////////////////////////////////////////////////
// Setup of data structures
//////////////////////////////////////////////////////////////////////
void HSolveActive::setup( Id seed, double dt )
{
//~ cout << ".. HA.setup()" << endl;
this->HSolvePassive::setup( seed, dt );
readHHChannels();
readGates();
readGateParams(); //Added for GPU execution
readCalcium();
createLookupTables();
readSynapses(); // Reads SynChans, SpikeGens. Drops process msg for SpikeGens.
readExternalChannels();
manageOutgoingMessages(); // Manages messages going out from the cell's components.
//~ reinit();
cleanup();
//~ cout << "# of compartments: " << compartmentId_.size() << "." << endl;
//~ cout << "# of channels: " << channelId_.size() << "." << endl;
//~ cout << "# of gates: " << gateId_.size() << "." << endl;
//~ cout << "# of states: " << state_.size() << "." << endl;
//~ cout << "# of Ca pools: " << caConc_.size() << "." << endl;
//~ cout << "# of SynChans: " << synchan_.size() << "." << endl;
//~ cout << "# of SpikeGens: " << spikegen_.size() << "." << endl;
}
void HSolveActive::reinit( ProcPtr info )
{
externalCurrent_.assign( externalCurrent_.size(), 0.0 );
reinitSpikeGens( info );
reinitCompartments();
reinitCalcium();
reinitChannels();
sendValues( info );
stage_ = 0;
}
void HSolveActive::reinitSpikeGens( ProcPtr info )
{
vector< SpikeGenStruct >::iterator ispike;
for ( ispike = spikegen_.begin(); ispike != spikegen_.end(); ++ispike )
ispike->reinit( info );
}
void HSolveActive::reinitCompartments()
{
for ( unsigned int ic = 0; ic < nCompt_; ++ic )
V_[ ic ] = tree_[ ic ].initVm;
}
void HSolveActive::reinitCalcium()
{
caActivation_.assign( caActivation_.size(), 0.0 );
for ( unsigned int i = 0; i < ca_.size(); ++i )
{
caConc_[ i ].c_ = 0.0;
ca_[ i ] = caConc_[ i ].CaBasal_;
}
}
void HSolveActive::reinitChannels()
{
vector< double >::iterator iv;
vector< double >::iterator istate = state_.begin();
vector< int >::iterator ichannelcount = channelCount_.begin();
vector< ChannelStruct >::iterator ichan = channel_.begin();
vector< ChannelStruct >::iterator chanBoundary;
vector< unsigned int >::iterator icacount = caCount_.begin();
vector< double >::iterator ica = ca_.begin();
vector< double >::iterator caBoundary;
vector< LookupColumn >::iterator icolumn = column_.begin();
vector< LookupRow >::iterator icarowcompt;
vector< LookupRow* >::iterator icarow = caRow_.begin();
LookupRow vRow;
double C1, C2;
for ( iv = V_.begin(); iv != V_.end(); ++iv )
{
vTable_.row( *iv, vRow );
icarowcompt = caRowCompt_.begin();
caBoundary = ica + *icacount;
for ( ; ica < caBoundary; ++ica )
{
caTable_.row( *ica, *icarowcompt );
++icarowcompt;
}
chanBoundary = ichan + *ichannelcount;
for ( ; ichan < chanBoundary; ++ichan )
{
if ( ichan->Xpower_ > 0.0 )
{
vTable_.lookup( *icolumn, vRow, C1, C2 );
*istate = C1 / C2;
++icolumn, ++istate;
}
if ( ichan->Ypower_ > 0.0 )
{
vTable_.lookup( *icolumn, vRow, C1, C2 );
*istate = C1 / C2;
++icolumn, ++istate;
}
if ( ichan->Zpower_ > 0.0 )
{
LookupRow* caRow = *icarow;
if ( caRow )
{
caTable_.lookup( *icolumn, *caRow, C1, C2 );
}
else
{
vTable_.lookup( *icolumn, vRow, C1, C2 );
}
*istate = C1 / C2;
++icolumn, ++istate, ++icarow;
}
}
++ichannelcount, ++icacount;
}
}
void HSolveActive::readHHChannels()
{
vector< Id >::iterator icompt;
vector< Id >::iterator ichan;
int nChannel = 0;
double Gbar = 0.0, Ek = 0.0;
double X = 0.0, Y = 0.0, Z = 0.0;
double Xpower = 0.0, Ypower = 0.0, Zpower = 0.0;
int instant = 0;
for ( icompt = compartmentId_.begin(); icompt != compartmentId_.end(); ++icompt )
{
nChannel = HSolveUtils::hhchannels( *icompt, channelId_ );
// todo: discard channels with Gbar = 0.0
channelCount_.push_back( nChannel );
ichan = channelId_.end() - nChannel;
for ( ; ichan != channelId_.end(); ++ichan )
{
channel_.resize( channel_.size() + 1 );
ChannelStruct& channel = channel_.back();
current_.resize( current_.size() + 1 );
CurrentStruct& current = current_.back();
Gbar = Field< double >::get( *ichan, "Gbar" );
Ek = Field< double >::get( *ichan, "Ek" );
X = Field< double >::get( *ichan, "X" );
Y = Field< double >::get( *ichan, "Y" );
Z = Field< double >::get( *ichan, "Z" );
Xpower = Field< double >::get( *ichan, "Xpower" );
Ypower = Field< double >::get( *ichan, "Ypower" );
Zpower = Field< double >::get( *ichan, "Zpower" );
instant = Field< int >::get( *ichan, "instant" );
current.Ek = Ek;
channel.Gbar_ = Gbar;
channel.setPowers( Xpower, Ypower, Zpower );
channel.instant_ = instant;
/*
* Map channel index to state index. This is useful in the
* interface to find gate values.
*/
chan2state_.push_back( state_.size() );
if ( Xpower > 0.0 )
state_.push_back( X );
if ( Ypower > 0.0 )
state_.push_back( Y );
if ( Zpower > 0.0 )
state_.push_back( Z );
/*
* Map channel index to compartment index. This is useful in the
* interface to generate channel Ik values (since we then need the
* compartment Vm).
*/
chan2compt_.push_back( icompt - compartmentId_.begin() );
}
}
int nCumulative = 0;
currentBoundary_.resize( nCompt_ );
for ( unsigned int ic = 0; ic < nCompt_; ++ic )
{
nCumulative += channelCount_[ ic ];
currentBoundary_[ ic ] = current_.begin() + nCumulative;
}
}
void HSolveActive::readGates()
{
vector< Id >::iterator ichan;
unsigned int nGates = 0;
int useConcentration = 0;
for ( ichan = channelId_.begin(); ichan != channelId_.end(); ++ichan )
{
nGates = HSolveUtils::gates( *ichan, gateId_ );
gCaDepend_.insert( gCaDepend_.end(), nGates, 0 );
useConcentration = Field< int >::get( *ichan, "useConcentration" );
if ( useConcentration )
gCaDepend_.back() = 1;
}
}
void HSolveActive::readGateParams()
{
vector< Id >::iterator ichan;
vector< ChannelStruct >::iterator ichan_st = channel_.begin();
for ( ichan = channelId_.begin(); ichan != channelId_.end(); ++ichan, ++ichan_st )
{
static string gateName[] = {
string( "gateX[0]" ),
string( "gateY[0]" ),
string( "gateZ[0]" )
};
static string powerField[] = {
string( "Xpower" ),
string( "Ypower" ),
string( "Zpower" )
};
unsigned int nGates = 3; // Number of possible gates
for ( unsigned int i = 0; i < nGates; i++ ) {
double power = Field< double >::get ( *ichan, powerField[i] );
if ( power > 0.0 ) {
string gatePath = moose::joinPath(ichan->path(), gateName[i]);
Id gate( gatePath );
string gPath = moose::fixPath(gate.path());
errorSS.str("");
errorSS << "Got " << gatePath << " expected " << gPath;
SIMPLE_ASSERT_MSG(gPath == gatePath, errorSS.str().c_str());
HHGate* g = reinterpret_cast< HHGate* >( gate.eref().data() );
switch(i)
{
case 0:
ichan_st->Xparams = Field< vector< double > >::get( g->originalGateId(), "AlphaParms" );
break;
case 1:
ichan_st->Yparams = Field< vector< double > >::get( g->originalGateId(), "AlphaParms" );
break;
case 2:
ichan_st->Zparams = Field< vector< double > >::get( g->originalGateId(), "AlphaParms" );
break;
}
}
}
}
}
void HSolveActive::readCalcium()
{
double Ca, CaBasal, tau, B, ceiling, floor;
vector< Id > caConcId;
vector< int > caTargetIndex;
map< Id, int > caConcIndex;
int nTarget, nDepend;
vector< Id >::iterator iconc;
caCount_.resize( nCompt_ );
unsigned int ichan = 0;
for ( unsigned int ic = 0; ic < nCompt_; ++ic )
{
unsigned int chanBoundary = ichan + channelCount_[ ic ];
unsigned int nCa = caConc_.size();
for ( ; ichan < chanBoundary; ++ichan )
{
caConcId.clear();
nTarget = HSolveUtils::caTarget( channelId_[ ichan ], caConcId );
if ( nTarget == 0 )
// No calcium pools fed by this channel.
caTargetIndex.push_back( -1 );
nDepend = HSolveUtils::caDepend( channelId_[ ichan ], caConcId );
if ( nDepend == 0 )
// Channel does not depend on calcium.
caDependIndex_.push_back( -1 );
for ( iconc = caConcId.begin(); iconc != caConcId.end(); ++iconc )
if ( caConcIndex.find( *iconc ) == caConcIndex.end() )
{
caConcIndex[ *iconc ] = caCount_[ ic ];
++caCount_[ ic ];
Ca = Field< double >::get( *iconc, "Ca" );
CaBasal = Field< double >::get( *iconc, "CaBasal" );
tau = Field< double >::get( *iconc, "tau" );
B = Field< double >::get( *iconc, "B" );
ceiling = Field< double >::get( *iconc, "ceiling" );
floor = Field< double >::get( *iconc, "floor" );
caConc_.push_back(
CaConcStruct(
Ca, CaBasal,
tau, B,
ceiling, floor,
dt_
)
);
caConcId_.push_back( *iconc );
}
if ( nTarget != 0 )
caTargetIndex.push_back( caConcIndex[ caConcId.front() ] + nCa );
if ( nDepend != 0 )
caDependIndex_.push_back( caConcIndex[ caConcId.back() ] );
}
}
caTarget_.resize( channel_.size() );
ca_.resize( caConc_.size() );
caActivation_.resize( caConc_.size() );
for ( unsigned int ichan = 0; ichan < channel_.size(); ++ichan )
{
if ( caTargetIndex[ ichan ] == -1 )
caTarget_[ ichan ] = 0;
else
caTarget_[ ichan ] = &caActivation_[ caTargetIndex[ ichan ] ];
}
}
void HSolveActive::createLookupTables()
{
std::set< Id > caSet;
std::set< Id > vSet;
vector< Id > caGate;
vector< Id > vGate;
map< Id, unsigned int > gateSpecies;
for ( unsigned int ig = 0; ig < gateId_.size(); ++ig )
if ( gCaDepend_[ ig ] )
caSet.insert( gateId_[ ig ] );
else
vSet.insert( gateId_[ ig ] );
caGate.insert( caGate.end(), caSet.begin(), caSet.end() );
vGate.insert( vGate.end(), vSet.begin(), vSet.end() );
for ( unsigned int ig = 0; ig < caGate.size(); ++ig )
gateSpecies[ caGate[ ig ] ] = ig;
for ( unsigned int ig = 0; ig < vGate.size(); ++ig )
gateSpecies[ vGate[ ig ] ] = ig;
/*
* Finding the smallest xmin and largest xmax across all gates' lookup
* tables.
*
* # of divs is determined by finding the smallest dx (highest density).
*/
vMin_ = numeric_limits< double >::max();
vMax_ = numeric_limits< double >::min();
double vDx = numeric_limits< double >::max();
caMin_ = numeric_limits< double >::max();
caMax_ = numeric_limits< double >::min();
double caDx = numeric_limits< double >::max();
double min;
double max;
unsigned int divs;
double dx;
for ( unsigned int ig = 0; ig < caGate.size(); ++ig )
{
min = Field< double >::get( caGate[ ig ], "min" );
max = Field< double >::get( caGate[ ig ], "max" );
divs = Field< unsigned int >::get( caGate[ ig ], "divs" );
dx = ( max - min ) / divs;
if ( min < caMin_ )
caMin_ = min;
if ( max > caMax_ )
caMax_ = max;
if ( dx < caDx )
caDx = dx;
}
double caDiv = ( caMax_ - caMin_ ) / caDx;
caDiv_ = static_cast< int >( caDiv + 0.5 ); // Round-off to nearest int.
for ( unsigned int ig = 0; ig < vGate.size(); ++ig )
{
min = Field< double >::get( vGate[ ig ], "min" );
max = Field< double >::get( vGate[ ig ], "max" );
divs = Field< unsigned int >::get( vGate[ ig ], "divs" );
dx = ( max - min ) / divs;
if ( min < vMin_ )
vMin_ = min;
if ( max > vMax_ )
vMax_ = max;
if ( dx < vDx )
vDx = dx;
}
double vDiv = ( vMax_ - vMin_ ) / vDx;
vDiv_ = static_cast< int >( vDiv + 0.5 ); // Round-off to nearest int.
caTable_ = LookupTable( caMin_, caMax_, caDiv_, caGate.size() );
vTable_ = LookupTable( vMin_, vMax_, vDiv_, vGate.size() );
vector< double > A, B;
vector< double >::iterator ia, ib;
// double a, b;
//~ int AMode, BMode;
//~ bool interpolate;
// Calcium-dependent lookup tables
HSolveUtils::Grid caGrid( caMin_, caMax_, caDiv_ );
//~ if ( !caGate.empty() ) {
//~ grid.resize( 1 + caDiv_ );
//~ double dca = ( caMax_ - caMin_ ) / caDiv_;
//~ for ( int igrid = 0; igrid <= caDiv_; ++igrid )
//~ grid[ igrid ] = caMin_ + igrid * dca;
//~ }
for ( unsigned int ig = 0; ig < caGate.size(); ++ig )
{
HSolveUtils::rates( caGate[ ig ], caGrid, A, B );
//~ HSolveUtils::modes( caGate[ ig ], AMode, BMode );
//~ interpolate = ( AMode == 1 ) || ( BMode == 1 );
ia = A.begin();
ib = B.begin();
for ( unsigned int igrid = 0; igrid < caGrid.size(); ++igrid )
{
// Use one of the optimized forms below, instead of A and B
// directly. Also updated reinit() accordingly (for gate state).
// a = *ia;
// b = *ib;
// *ia = ( 2.0 - dt_ * b ) / ( 2.0 + dt_ * b );
// *ib = dt_ * a / ( 1.0 + dt_ * b / 2.0 );
// *ia = dt_ * a;
// *ib = 1.0 + dt_ * b / 2.0;
++ia, ++ib;
}
//~ caTable_.addColumns( ig, A, B, interpolate );
caTable_.addColumns( ig, A, B );
}
// Voltage-dependent lookup tables
HSolveUtils::Grid vGrid( vMin_, vMax_, vDiv_ );
//~ if ( !vGate.empty() ) {
//~ grid.resize( 1 + vDiv_ );
//~ double dv = ( vMax_ - vMin_ ) / vDiv_;
//~ for ( int igrid = 0; igrid <= vDiv_; ++igrid )
//~ grid[ igrid ] = vMin_ + igrid * dv;
//~ }
for ( unsigned int ig = 0; ig < vGate.size(); ++ig )
{
//~ interpolate = HSolveUtils::get< HHGate, bool >( vGate[ ig ], "useInterpolation" );
HSolveUtils::rates( vGate[ ig ], vGrid, A, B );
//~ HSolveUtils::modes( vGate[ ig ], AMode, BMode );
//~ interpolate = ( AMode == 1 ) || ( BMode == 1 );
ia = A.begin();
ib = B.begin();
for ( unsigned int igrid = 0; igrid < vGrid.size(); ++igrid )
{
// Use one of the optimized forms below, instead of A and B
// directly. Also updated reinit() accordingly (for gate state).
// a = *ia;
// b = *ib;
// *ia = ( 2.0 - dt_ * b ) / ( 2.0 + dt_ * b );
// *ib = dt_ * a / ( 1.0 + dt_ * b / 2.0 );
// *ia = dt_ * a;
// *ib = 1.0 + dt_ * b / 2.0;
++ia, ++ib;
}
//~ vTable_.addColumns( ig, A, B, interpolate );
vTable_.addColumns( ig, A, B );
}
column_.reserve( gateId_.size() );
for ( unsigned int ig = 0; ig < gateId_.size(); ++ig )
{
unsigned int species = gateSpecies[ gateId_[ ig ] ];
LookupColumn column;
if ( gCaDepend_[ ig ] )
caTable_.column( species, column );
else
vTable_.column( species, column );
column_.push_back( column );
}
///////////////////!!!!!!!!!!
unsigned int maxN = *( max_element( caCount_.begin(), caCount_.end() ) );
caRowCompt_.resize( maxN );
for ( unsigned int ichan = 0; ichan < channel_.size(); ++ichan )
{
if ( channel_[ ichan ].Zpower_ > 0.0 )
{
int index = caDependIndex_[ ichan ];
if ( index == -1 )
caRow_.push_back( 0 );
else
caRow_.push_back( &caRowCompt_[ index ] );
}
}
}
/**
* Reads in SynChans and SpikeGens.
*
* Unlike Compartments, HHChannels, etc., neither of these are zombified.
* In other words, their fields are not managed by HSolve, and their "process"
* functions are invoked to do their calculations. For SynChans, the process
* calls are made by their respective clocks, and hence the process message is
* not dropped. On the other hand, we drop the SpikeGen process messages here,
* and explicitly call the SpikeGen process() from the HSolve via a pointer.
*/
void HSolveActive::readSynapses()
{
vector< Id > spikeId;
vector< Id > synId;
vector< Id >::iterator syn;
vector< Id >::iterator spike;
SynChanStruct synchan;
for ( unsigned int ic = 0; ic < nCompt_; ++ic )
{
synId.clear();
HSolveUtils::synchans( compartmentId_[ ic ], synId );
for ( syn = synId.begin(); syn != synId.end(); ++syn )
{
synchan.compt_ = ic;
synchan.elm_ = *syn;
synchan_.push_back( synchan );
}
static const Finfo* procDest = SpikeGen::initCinfo()->findFinfo( "process");
assert( procDest );
const DestFinfo* df = dynamic_cast< const DestFinfo* >( procDest );
assert( df );
spikeId.clear();
HSolveUtils::spikegens( compartmentId_[ ic ], spikeId );
// Very unlikely that there will be >1 spikegens in a compartment,
// but lets take care of it anyway.
for ( spike = spikeId.begin(); spike != spikeId.end(); ++spike )
{
spikegen_.push_back(
SpikeGenStruct( &V_[ ic ], spike->eref() )
);
ObjId mid = spike->element()->findCaller( df->getFid() );
if ( ! mid.bad() )
Msg::deleteMsg( mid );
}
}
}
void HSolveActive::readExternalChannels()
{
vector< string > filter;
filter.push_back( "HHChannel" );
//~ filter.push_back( "SynChan" );
//~ externalChannelId_.resize( compartmentId_.size() );
externalCurrent_.resize( 2 * compartmentId_.size(), 0.0 );
//~ for ( unsigned int ic = 0; ic < compartmentId_.size(); ++ic )
//~ HSolveUtils::targets(
//~ compartmentId_[ ic ],
//~ "channel",
//~ externalChannelId_[ ic ],
//~ filter,
//~ false // include = false. That is, use filter to exclude.
//~ );
}
void HSolveActive::manageOutgoingMessages()
{
vector< Id > targets;
vector< string > filter;
/*
* Going through all comparments, and finding out which ones have external
* targets through the VmOut msg. External refers to objects that do not
* belong the cell being managed by this HSolve. We find these by excluding
* any HHChannels and SpikeGens from the VmOut targets. These will then
* be used in HSolveActive::sendValues() to send out the messages behalf of
* the original objects.
*/
filter.push_back( "HHChannel" );
filter.push_back( "SpikeGen" );
for ( unsigned int ic = 0; ic < compartmentId_.size(); ++ic )
{
targets.clear();
int nTargets = HSolveUtils::targets(
compartmentId_[ ic ],
"VmOut",
targets,
filter,
false // include = false. That is, use filter to exclude.
);
if ( nTargets )
outVm_.push_back( ic );
}
/*
* As before, going through all CaConcs, and finding any which have external
* targets.
*/
filter.clear();
filter.push_back( "HHChannel" );
for ( unsigned int ica = 0; ica < caConcId_.size(); ++ica )
{
targets.clear();
int nTargets = HSolveUtils::targets(
caConcId_[ ica ],
"concOut",
targets,
filter,
false // include = false. That is, use filter to exclude.
);
if ( nTargets )
outCa_.push_back( ica );
}
}
void HSolveActive::cleanup()
{
// compartmentId_.clear();
gCaDepend_.clear();
caDependIndex_.clear();
}