Skip to content

Commit

Permalink
removed camel case in proto file
Browse files Browse the repository at this point in the history
  • Loading branch information
mudiagaobrikisil committed Dec 2, 2024
2 parents 3cb8e1f + 40084eb commit 3dcedf4
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 32 deletions.
30 changes: 15 additions & 15 deletions samples/ServalApp/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions samples/ServalApp/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ streamlit = "^1.31.1"
requests = "^2.31.0"
SQLAlchemy = "^2.0.22"
pyarrow = "^14.0.1"
tornado = "^6.4.2"

[tool.poetry.group.dev.dependencies]
black = "^23.10.1"
Expand Down
26 changes: 13 additions & 13 deletions scripts/clearml_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import json
import os
import pickle
from datetime import datetime, timezone
from datetime import datetime

import numpy as np
import pandas as pd
Expand Down Expand Up @@ -47,6 +47,13 @@ class clearml_stats:
def __init__(self):
self._client: APIClient = APIClient()
self._tasks: dict[str, dict] = self._read_tasks()
self._project_id_to_task_id: dict[str, list[str]] = {}
for task_id in self._tasks.keys():
project_id = self._tasks[task_id]["project"]
if project_id in self._project_id_to_task_id:
self._project_id_to_task_id[project_id].append(task_id)
else:
self._project_id_to_task_id[project_id] = [task_id]
self._projects: dict[str, dict] = self._read_projects()
self._languages: pd.DataFrame = pd.read_excel(
language_database_filename, index_col=0
Expand Down Expand Up @@ -306,24 +313,14 @@ def add_lang(lang):
else:
langs_by_occurrence[lang] = 1

num_of_tasks_found = 0
num_of_tasks_not_found = 0
for project_id in self._projects:
self._projects[project_id]["src_lang"] = "unknown"
self._projects[project_id]["trg_lang"] = "unknown"
self._projects[project_id]["lang_candidates"] = []

project = self._projects[project_id]
if len(project["tasks"]) > 0:
task_not_found = True
for task_id in project["tasks"]:
if task_id in self._tasks.keys():
task_not_found = False
break
if task_not_found:
num_of_tasks_not_found += 1
continue
num_of_tasks_found += 1
if project_id in self._project_id_to_task_id:
project["tasks"] = self._project_id_to_task_id[project_id]
task = self._tasks[project["tasks"][0]]
args = task["script_args"]
if "src_lang" in args and "trg_lang" in args:
Expand Down Expand Up @@ -491,3 +488,6 @@ def violin_task_delay_time_per_week(
axes.set_ylim(0, 8)
axes.set_ylabel("hours")
axes.grid(True)


# %%
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,5 @@ message InsertPretranslationsRequest {
message UpdateBuildExecutionDataRequest {
string engine_id = 1;
string build_id = 2;
map<string, string> ExecutionData = 3;
map<string, string> execution_data = 3;
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Serval.Translation.Contracts;
namespace Serval.Translation.Contracts;

public record TranslationBuildDto
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Serval.Translation.Controllers;
namespace Serval.Translation.Controllers;

#pragma warning disable CS0612 // Type or member is obsolete

Expand Down
2 changes: 1 addition & 1 deletion src/Serval/src/Serval.Translation/Models/Build.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Serval.Translation.Models;
namespace Serval.Translation.Models;

public record Build : IEntity
{
Expand Down

0 comments on commit 3dcedf4

Please sign in to comment.