headers
Some checks failed
build_docker / build_cpu (pull_request) Successful in 5m16s
build_docker / build_easyocr_gpu (pull_request) Has been cancelled
build_docker / build_doctr (pull_request) Has been cancelled
build_docker / build_doctr_gpu (pull_request) Has been cancelled
build_docker / build_raytune (pull_request) Has been cancelled
build_docker / build_gpu (pull_request) Has been cancelled
build_docker / build_easyocr (pull_request) Has been cancelled
build_docker / essential (pull_request) Successful in 1s
Some checks failed
build_docker / build_cpu (pull_request) Successful in 5m16s
build_docker / build_easyocr_gpu (pull_request) Has been cancelled
build_docker / build_doctr (pull_request) Has been cancelled
build_docker / build_doctr_gpu (pull_request) Has been cancelled
build_docker / build_raytune (pull_request) Has been cancelled
build_docker / build_gpu (pull_request) Has been cancelled
build_docker / build_easyocr (pull_request) Has been cancelled
build_docker / essential (pull_request) Successful in 1s
This commit is contained in:
@@ -22,8 +22,10 @@ Review and validate the documentation for this Master's Thesis project.
|
|||||||
- Verify: dataset size (pages)
|
- Verify: dataset size (pages)
|
||||||
|
|
||||||
### UNIR Formatting
|
### UNIR Formatting
|
||||||
- Tables: `**Tabla N.** *Title in italics.*` followed by table, then `*Fuente: ...*`
|
- Tables: `**Tabla N.** *Descriptive title in italics.*` followed by table, then `*Fuente: ...*`
|
||||||
- Figures: `**Figura N.** *Title in italics.*`
|
- Table titles must describe the content (e.g., "Comparación de modelos OCR")
|
||||||
|
- Figures: `**Figura N.** *Descriptive title in italics.*`
|
||||||
|
- Figure titles must describe the content (e.g., "Pipeline de un sistema OCR moderno")
|
||||||
- Sequential numbering (no duplicates, no gaps)
|
- Sequential numbering (no duplicates, no gaps)
|
||||||
- APA citation format for references
|
- APA citation format for references
|
||||||
|
|
||||||
@@ -46,6 +48,8 @@ Review and validate the documentation for this Master's Thesis project.
|
|||||||
A[Node] --> B[Node]
|
A[Node] --> B[Node]
|
||||||
```
|
```
|
||||||
- Colors: `#0098CD` (UNIR blue for borders/lines), `#E6F4F9` (light blue background)
|
- Colors: `#0098CD` (UNIR blue for borders/lines), `#E6F4F9` (light blue background)
|
||||||
|
- All diagrams must have a descriptive `title:` in YAML frontmatter
|
||||||
|
- Titles should describe the diagram content, not generic "Diagrama N"
|
||||||
- Verify theme is applied to all diagrams in `docs/*.md`
|
- Verify theme is applied to all diagrams in `docs/*.md`
|
||||||
|
|
||||||
### Files to Review
|
### Files to Review
|
||||||
|
|||||||
@@ -145,7 +145,7 @@ def parse_md_to_html_blocks(md_content):
|
|||||||
|
|
||||||
if os.path.exists(fig_path):
|
if os.path.exists(fig_path):
|
||||||
# Use Word-compatible width in cm (A4 text area is ~16cm wide, use ~12cm max)
|
# Use Word-compatible width in cm (A4 text area is ~16cm wide, use ~12cm max)
|
||||||
html_blocks.append(f'''<p class=MsoNormal style="text-align:center"><span lang=ES><img style="width:12cm;max-width:100%" src="{fig_file}" alt="{fig_title}"/></span></p>''')
|
html_blocks.append(f'''<p class=MsoNormal style="text-align:center"><span lang=ES><img style="max-width:16cm;max-height:20cm;width:auto;height:auto" src="{fig_file}" alt="{fig_title}"/></span></p>''')
|
||||||
else:
|
else:
|
||||||
# Fallback to placeholder
|
# Fallback to placeholder
|
||||||
html_blocks.append(f'''<p class=MsoNormal style="text-align:center;border:1px dashed #999;padding:20px;margin:10px 40px;background:#f9f9f9"><span lang=ES style="color:#666">[Insertar diagrama Mermaid aquí]</span></p>''')
|
html_blocks.append(f'''<p class=MsoNormal style="text-align:center;border:1px dashed #999;padding:20px;margin:10px 40px;background:#f9f9f9"><span lang=ES style="color:#666">[Insertar diagrama Mermaid aquí]</span></p>''')
|
||||||
@@ -240,7 +240,8 @@ def parse_md_to_html_blocks(md_content):
|
|||||||
html_blocks.append(f'''<a name="{bookmark_id}"></a><p class=MsoCaption><b><span lang=ES style="font-size:12.0pt;line-height:150%">Tabla <!--[if supportFields]><span style='mso-element:field-begin'></span> SEQ Tabla \\* ARABIC <span style='mso-element:field-separator'></span><![endif]-->{table_counter}<!--[if supportFields]><span style='mso-element:field-end'></span><![endif]-->.</span></b><span lang=ES style="font-size:12.0pt;line-height:150%"> </span><i><span lang=ES style="font-size:12.0pt;line-height:150%">{clean_title}</span></i></p>''')
|
html_blocks.append(f'''<a name="{bookmark_id}"></a><p class=MsoCaption><b><span lang=ES style="font-size:12.0pt;line-height:150%">Tabla <!--[if supportFields]><span style='mso-element:field-begin'></span> SEQ Tabla \\* ARABIC <span style='mso-element:field-separator'></span><![endif]-->{table_counter}<!--[if supportFields]><span style='mso-element:field-end'></span><![endif]-->.</span></b><span lang=ES style="font-size:12.0pt;line-height:150%"> </span><i><span lang=ES style="font-size:12.0pt;line-height:150%">{clean_title}</span></i></p>''')
|
||||||
|
|
||||||
# Build table HTML with APA style (horizontal lines only, no vertical)
|
# Build table HTML with APA style (horizontal lines only, no vertical)
|
||||||
table_html = '<table class=MsoTableGrid border=1 cellspacing=0 cellpadding=0 style="border-collapse:collapse;margin-left:auto;margin-right:auto;mso-table-style-name:\'Plain Table 1\'">'
|
# Wrap in centered div for Word compatibility
|
||||||
|
table_html = '<div align="center"><table class=MsoTableGrid border=1 cellspacing=0 cellpadding=0 align="center" style="border-collapse:collapse;margin-left:auto;margin-right:auto;mso-table-style-name:\'Plain Table 1\'">'
|
||||||
for j, tline in enumerate(table_lines):
|
for j, tline in enumerate(table_lines):
|
||||||
cells = [c.strip() for c in tline.split('|')[1:-1]]
|
cells = [c.strip() for c in tline.split('|')[1:-1]]
|
||||||
table_html += '<tr>'
|
table_html += '<tr>'
|
||||||
@@ -255,7 +256,7 @@ def parse_md_to_html_blocks(md_content):
|
|||||||
# Middle rows: no borders
|
# Middle rows: no borders
|
||||||
table_html += f'<td style="border:none;padding:5px"><p class=MsoNormal style="margin:0;text-align:center"><span lang=ES>{md_to_html_para(cell)}</span></p></td>'
|
table_html += f'<td style="border:none;padding:5px"><p class=MsoNormal style="margin:0;text-align:center"><span lang=ES>{md_to_html_para(cell)}</span></p></td>'
|
||||||
table_html += '</tr>'
|
table_html += '</tr>'
|
||||||
table_html += '</table>'
|
table_html += '</table></div>'
|
||||||
html_blocks.append(table_html)
|
html_blocks.append(table_html)
|
||||||
|
|
||||||
# Add source with proper template format
|
# Add source with proper template format
|
||||||
|
|||||||
@@ -35,10 +35,12 @@ def extract_mermaid_diagrams():
|
|||||||
matches = re.findall(pattern, content, re.DOTALL)
|
matches = re.findall(pattern, content, re.DOTALL)
|
||||||
|
|
||||||
for i, mermaid_code in enumerate(matches):
|
for i, mermaid_code in enumerate(matches):
|
||||||
# Try to extract title from YAML front matter or inline title
|
# Try to extract title from YAML front matter
|
||||||
|
# Match title with quotes: title: "Something" or title: 'Something'
|
||||||
title_match = re.search(r'title:\s*["\']([^"\']+)["\']', mermaid_code)
|
title_match = re.search(r'title:\s*["\']([^"\']+)["\']', mermaid_code)
|
||||||
if not title_match:
|
if not title_match:
|
||||||
title_match = re.search(r'title\s+["\']?([^"\'"\n]+)["\']?', mermaid_code)
|
# Match title without quotes: title: Something
|
||||||
|
title_match = re.search(r'title:\s*([^"\'\n]+)', mermaid_code)
|
||||||
title = title_match.group(1).strip() if title_match else f"Diagrama {len(diagrams) + 1}"
|
title = title_match.group(1).strip() if title_match else f"Diagrama {len(diagrams) + 1}"
|
||||||
|
|
||||||
diagrams.append({
|
diagrams.append({
|
||||||
|
|||||||
@@ -1,32 +1,32 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"file": "figura_1.png",
|
"file": "figura_1.png",
|
||||||
"title": "Diagrama 1",
|
"title": "Pipeline de un sistema OCR moderno",
|
||||||
"index": 1
|
"index": 1
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"file": "figura_2.png",
|
"file": "figura_2.png",
|
||||||
"title": "Diagrama 2",
|
"title": "Ciclo de optimización con Ray Tune y Optuna",
|
||||||
"index": 2
|
"index": 2
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"file": "figura_3.png",
|
"file": "figura_3.png",
|
||||||
"title": "Diagrama 3",
|
"title": "Fases de la metodología experimental",
|
||||||
"index": 3
|
"index": 3
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"file": "figura_4.png",
|
"file": "figura_4.png",
|
||||||
"title": "Diagrama 4",
|
"title": "Estructura del dataset de evaluación",
|
||||||
"index": 4
|
"index": 4
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"file": "figura_5.png",
|
"file": "figura_5.png",
|
||||||
"title": "Diagrama 5",
|
"title": "Arquitectura de ejecución con Docker Compose",
|
||||||
"index": 5
|
"index": 5
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"file": "figura_6.png",
|
"file": "figura_6.png",
|
||||||
"title": "Diagrama 6",
|
"title": "Arquitectura de microservicios para optimización OCR",
|
||||||
"index": 6
|
"index": 6
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user