Skip to content

Commit

Permalink
[GPUPS]Fix set ins id (PaddlePaddle#72)
Browse files Browse the repository at this point in the history
* fix sparse_ssd_unseenday_threshold

* fix set insid
  • Loading branch information
zmxdream authored Nov 9, 2022
1 parent 09fc7c8 commit c5a11a9
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions paddle/fluid/framework/data_feed.h
Original file line number Diff line number Diff line change
Expand Up @@ -1483,16 +1483,6 @@ class SlotRecordInMemoryDataFeed : public InMemoryDataFeed<SlotRecord> {
virtual void Init(const DataFeedDesc& data_feed_desc);
virtual void LoadIntoMemory();
void ExpandSlotRecord(SlotRecord* ins);

protected:
virtual bool Start();
virtual int Next();
virtual bool ParseOneInstance(SlotRecord* instance) { return false; }
virtual bool ParseOneInstanceFromPipe(SlotRecord* instance) { return false; }
// virtual void ParseOneInstanceFromSo(const char* str, T* instance,
// CustomParser* parser) {}
virtual void PutToFeedVec(const std::vector<SlotRecord>& ins_vec) {}

virtual void SetInsIdVec(MiniBatchGpuPack* pack) {
if (parse_ins_id_) {
size_t ins_num = pack->ins_num();
Expand All @@ -1504,6 +1494,15 @@ class SlotRecordInMemoryDataFeed : public InMemoryDataFeed<SlotRecord> {
}
}

protected:
virtual bool Start();
virtual int Next();
virtual bool ParseOneInstance(SlotRecord* instance) { return false; }
virtual bool ParseOneInstanceFromPipe(SlotRecord* instance) { return false; }
// virtual void ParseOneInstanceFromSo(const char* str, T* instance,
// CustomParser* parser) {}
virtual void PutToFeedVec(const std::vector<SlotRecord>& ins_vec) {}

virtual void LoadIntoMemoryByCommand(void);
virtual void LoadIntoMemoryByLib(void);
virtual void LoadIntoMemoryByLine(void);
Expand Down

0 comments on commit c5a11a9

Please sign in to comment.