Skip to content

Commit

Permalink
Unbuffered output from conda
Browse files Browse the repository at this point in the history
  • Loading branch information
phlobo committed Dec 5, 2024
1 parent 3d5011a commit a5b0969
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ RUN python download_models.py
EXPOSE 5000

# Define the command to run the server with parameters
CMD ["conda", "run", "-n", "xmen", "python3", "run_snomed_german_recommender.py", "--no-gpu", "--port", "5000", "index", "--num_recs", "10"]
CMD ["conda", "run", "--no-capture-output", "-n", "xmen", "python3", "-u", "run_snomed_german_recommender.py", "--no-gpu", "--port", "5000", "index", "--num_recs", "10"]
4 changes: 2 additions & 2 deletions run_snomed_german_recommender.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@ def run():

# Suppress InconsistentVersionWarning from TF-IDF vectorizer
warnings.filterwarnings("ignore", category=InconsistentVersionWarning)
print("Loading xMEN SNOMED Linker...", flush=True)
print("Loading xMEN SNOMED Linker...")
linker = default_ensemble(args.index_base_path, cuda=args.gpu)

print("Starting Ariadne server...", flush=True)
print("Starting Ariadne server...")
server = Server()
server.add_classifier("xmen_snomed", xMENSNOMEDLinker(linker, top_k=args.num_recs))

Expand Down

0 comments on commit a5b0969

Please sign in to comment.