This repository has been archived by the owner on Feb 22, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 209
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(base): later import module now override the earlier ones
- Loading branch information
hanhxiao
committed
Aug 20, 2019
1 parent
fa69eb8
commit ffb7fe4
Showing
7 changed files
with
75 additions
and
6 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
from gnes.indexer.base import BaseVectorIndexer | ||
|
||
|
||
class FaissIndexer(BaseVectorIndexer): | ||
|
||
def __init__(self, bar: int, *args, **kwargs): | ||
super().__init__(*args, **kwargs) | ||
self.is_trained = True | ||
self.bar = bar | ||
self.logger.info('look at me, I override the original GNES faiss indexer') | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
!FaissIndexer | ||
parameters: | ||
bar: 531 | ||
gnes_config: | ||
name: foo_contrib_encoder |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
from gnes.indexer.base import BaseVectorIndexer | ||
|
||
|
||
class FaissIndexer(BaseVectorIndexer): | ||
|
||
def __init__(self, bar: int, *args, **kwargs): | ||
super().__init__(*args, **kwargs) | ||
self.is_trained = True | ||
self.bar = bar | ||
self.logger.info('look at me, I override the overrided faiss indexer!!!') | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters