Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update pt.terrier.Retriever __str__ and __repr__ #474

Merged
merged 5 commits into from
Aug 23, 2024
Merged

Conversation

cmacdonald
Copy link
Contributor

{wip}

These will be viewable by all users who dont use names=[] in -pt.Experiment()

@cmacdonald
Copy link
Contributor Author

Here is what a new new experiment looks like:

>>> pt.Experiment([br, br >> pt.rewrite.Bo1QueryExpansion(br.indexref) >> br], dataset.get_topics(), dataset.get_qrels(), ["map"])
                                                name       map
0                                     pt.t.Retr(DPH)  0.283614
1  Compose(Compose(pt.t.Retr(DPH), QueryExpansion...  0.295955

@seanmacavaney
Copy link
Collaborator

Let me think a bit on this...

On the one hand, it's nice to have short, abbreviated names here to be concise.

On the other hand, the current form might look too much like an actual python statement -- and pt.t.Retr doesn't exist.

How about TerrierRetr(DPH)? Only 2 characters longer.

@cmacdonald
Copy link
Contributor Author

How about TerrierRetr(DPH)? Only 2 characters longer.

The featured one is much longer of course.

@seanmacavaney
Copy link
Collaborator

TerrierFeatRetr?

@cmacdonald cmacdonald merged commit c663a73 into master Aug 23, 2024
17 checks passed
@cmacdonald cmacdonald deleted the retr_repr branch August 23, 2024 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants