Renal transplantation
All topic map
Create a renal transplantation quick-reference PDF
"Kidney Transplantation"[MeSH Terms]
KDIGO clinical practice guideline kidney transplant recipient care official
~/
mkdir -p "/tmp/workspace/renal-transplant-quick-reference/src" "/tmp/workspace/renal-transplant-quick-reference/output"
~/renal-transplant-quick-reference/src/create_pdf.py
from reportlab.lib import colors
from reportlab.lib.enums import TA_CENTER
from reportlab.lib.pagesizes import A4
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.units import cm
from reportlab.platypus import SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle, PageBreak, KeepTogether
from reportlab.pdfbase.ttfonts import TTFont
from reportlab.pdfbase import pdfmetrics
from reportlab.lib.colors import HexColor
from reportlab.pdfbase.pdfmetrics import stringWidth
OUT = '/tmp/workspace/renal-transplant-quick-reference/output/Renal_Transplantation_Quick_Reference.pdf'
NAVY=HexColor('#12314A'); TEAL=HexColor('#087E8B'); SKY=HexColor('#EAF5F6'); PALE=HexColor('#F5F8FA'); RED=HexColor('#A51C30'); AMBER=HexColor('#FFF4D6'); GREEN=HexColor('#E8F4EA'); GRAY=HexColor('#5B6870')
styles=getSampleStyleSheet()
styles.add(ParagraphStyle(name='Title2', parent=styles['Title'], fontName='Helvetica-Bold', fontSize=23, leading=27, textColor=NAVY, alignment=TA_CENTER, spaceAfter=5))
styles.add(ParagraphStyle(name='Sub', parent=styles['Normal'], fontName='Helvetica', fontSize=9.2, leading=12, textColor=GRAY, alignment=TA_CENTER, spaceAfter=11))
styles.add(ParagraphStyle(name='H1x', parent=styles['Heading1'], fontName='Helvetica-Bold', fontSize=14, leading=17, textColor=NAVY, spaceBefore=8, spaceAfter=5))
styles.add(ParagraphStyle(name='H2x', parent=styles['Heading2'], fontName='Helvetica-Bold', fontSize=10.5, leading=13, textColor=TEAL, spaceBefore=5, spaceAfter=3))
styles.add(ParagraphStyle(name='Bodyx', parent=styles['BodyText'], fontName='Helvetica', fontSize=8.25, leading=10.8, textColor=HexColor('#18242B'), spaceAfter=3))
styles.add(ParagraphStyle(name='Small', parent=styles['BodyText'], fontName='Helvetica', fontSize=7.1, leading=9, textColor=HexColor('#26343B')))
styles.add(ParagraphStyle(name='Call', parent=styles['BodyText'], fontName='Helvetica-Bold', fontSize=8.4, leading=11, textColor=RED))
def P(text, sty='Bodyx'): return Paragraph(text, styles[sty])
def bullets(items): return [P('• '+x) for x in items]
def box(title, items, bg=PALE):
content=[P(title,'H2x')]+bullets(items)
t=Table([[content]], colWidths=[17.0*cm])
t.setStyle(TableStyle([('BACKGROUND',(0,0),(-1,-1),bg),('BOX',(0,0),(-1,-1),0.45,HexColor('#B7C8D2')),('LEFTPADDING',(0,0),(-1,-1),8),('RIGHTPADDING',(0,0),(-1,-1),8),('TOPPADDING',(0,0),(-1,-1),4),('BOTTOMPADDING',(0,0),(-1,-1),4)]))
return t
def tbl(rows, widths, header=True):
cooked=[]
for r, row in enumerate(rows): cooked.append([P(c, 'Small' if r else 'Small') for c in row])
t=Table(cooked,colWidths=widths,repeatRows=1 if header else 0,hAlign='LEFT')
st=[('VALIGN',(0,0),(-1,-1),'TOP'),('GRID',(0,0),(-1,-1),0.3,HexColor('#C8D5DB')),('LEFTPADDING',(0,0),(-1,-1),5),('RIGHTPADDING',(0,0),(-1,-1),5),('TOPPADDING',(0,0),(-1,-1),4),('BOTTOMPADDING',(0,0),(-1,-1),4)]
if header: st += [('BACKGROUND',(0,0),(-1,0),NAVY),('TEXTCOLOR',(0,0),(-1,0),colors.white)]
for r in range(1,len(rows)):
if r%2==0: st.append(('BACKGROUND',(0,r),(-1,r),PALE))
t.setStyle(TableStyle(st)); return t
def header_footer(canvas, doc):
canvas.saveState(); w,h=A4
canvas.setStrokeColor(TEAL); canvas.setLineWidth(1.2); canvas.line(1.5*cm,h-1.2*cm,w-1.5*cm,h-1.2*cm)
canvas.setFont('Helvetica',7.5); canvas.setFillColor(GRAY)
canvas.drawString(1.5*cm,0.75*cm,'Renal Transplantation Quick Reference | Educational use only')
canvas.drawRightString(w-1.5*cm,0.75*cm,f'Page {doc.page}')
canvas.restoreState()
doc=SimpleDocTemplate(OUT,pagesize=A4,rightMargin=1.5*cm,leftMargin=1.5*cm,topMargin=1.55*cm,bottomMargin=1.25*cm)
story=[]
story += [P('RENAL TRANSPLANTATION','Title2'),P('Clinical quick-reference for adult kidney transplant candidates and recipients','Sub')]
story.append(box('Scope and safety', ['This summary supports study and point-of-care orientation. Transplant-center protocols, local microbiology, drug levels, donor-specific factors, and specialist assessment determine actual care.', 'Any fall in urine output, rising creatinine, fever, graft pain, or suspected medication toxicity warrants prompt transplant-team contact. Do not independently stop or alter immunosuppression.'], AMBER))
story += [P('1. When to consider transplantation','H1x'),P('<b>Indication:</b> kidney failure requiring kidney replacement therapy, or anticipated need, when expected benefit exceeds risk. Pre-emptive living-donor transplantation is preferred where feasible. Assess cardiovascular status, infection, malignancy history, vascular anatomy, adherence capacity, psychosocial support, and cause of kidney disease.', 'Bodyx')]
story.append(tbl([
['Donor pathway','Key points'],
['Living donor','Usually offers shorter waiting time and better outcomes. Assess medical and psychosocial suitability, renal function, blood pressure, albuminuria, diabetes risk, anatomy, and informed voluntary consent.'],
['Deceased donor','Allocation reflects blood group, HLA sensitization, waiting time and local policy. Kidney quality and cold-ischaemia time affect risk of delayed graft function.'],
['Compatibility','ABO compatibility and HLA antibody assessment/crossmatch reduce immunologic risk. ABO- or HLA-incompatible transplant may be possible in selected specialist programs.']
],[4.1*cm,12.9*cm]))
story += [P('2. Operation and early postoperative priorities','H1x'),P('The graft is generally placed <b>extraperitoneally in an iliac fossa</b>. Renal vein and artery are anastomosed to iliac vessels, and the ureter is implanted into the bladder. Native kidneys are usually left in place. Monitor haemodynamics, urine output, fluid balance, creatinine, electrolytes, haemoglobin, wound/drains, and Doppler ultrasound when vascular or obstructive complications are suspected.','Bodyx')]
story.append(box('Early differential for poor graft function', ['Pre-renal/haemodynamic: hypovolaemia, hypotension, cardiac dysfunction.', 'Parenchymal: ischaemia-reperfusion injury or acute tubular injury, acute rejection, calcineurin-inhibitor toxicity, recurrent/de novo renal disease.', 'Post-renal/vascular: ureteric obstruction or leak, renal artery/vein thrombosis or stenosis, perinephric collection. Use urgent ultrasound with Doppler and involve the transplant team; biopsy is often needed after reversible structural, infectious and drug causes are assessed.'], SKY))
story += [P('3. Immunosuppression','H1x')]
story.append(tbl([
['Phase','Common approach and key cautions'],
['Induction','An interleukin-2 receptor antagonist (for example basiliximab) or lymphocyte-depleting agent (for example rabbit anti-thymocyte globulin), selected by immunologic risk and center protocol.'],
['Maintenance','Usually a calcineurin inhibitor (often tacrolimus) + antimetabolite (mycophenolate mofetil/mycophenolic acid or azathioprine) + corticosteroid, with individualized steroid minimization/withdrawal in selected recipients. Alternatives include mTOR inhibitors or belatacept in appropriate settings.'],
['Monitoring','Check adherence, trough concentrations where indicated, creatinine/eGFR, potassium, magnesium, glucose, blood pressure, blood count, liver tests, proteinuria and adverse effects. Interactions are frequent: consult transplant pharmacy before adding antimicrobials, antifungals, anticonvulsants, herbal products or other drugs.']
],[3.25*cm,13.75*cm]))
story.append(PageBreak())
story += [P('4. Rejection and graft dysfunction','H1x')]
story.append(tbl([
['Type','Typical mechanism / approach'],
['Hyperacute','Preformed recipient antibodies cause immediate thrombosis and graft nonfunction. Prevention depends on antibody screening and negative compatible crossmatch.'],
['Acute T-cell-mediated rejection','Often presents with rising creatinine, sometimes fever, graft tenderness, reduced urine output or no symptoms. Confirm with biopsy when feasible. Treat commonly with high-dose corticosteroids; more severe/steroid-resistant disease may require lymphocyte-depleting therapy.'],
['Antibody-mediated rejection','Requires clinicopathologic correlation: graft dysfunction, biopsy features, donor-specific antibodies and complement staining where relevant. Management is individualized, often using combinations such as plasma exchange, IV immunoglobulin and intensified/targeted immunotherapy.'],
['Chronic active injury','Progressive dysfunction/proteinuria from chronic rejection, recurrent disease, CNI toxicity, hypertension and other causes. Biopsy guides management; preserve nephron function and manage modifiable risks.']
],[4.2*cm,12.8*cm]))
story.append(box('Rising creatinine: practical sequence', ['Confirm trend; review fluid status, blood pressure, urine output and drug adherence.', 'Check urinalysis/culture when infection possible, serum drug levels where relevant, blood count and chemistry.', 'Ultrasound with Doppler to assess perfusion, hydronephrosis and collections. Screen for BK/CMV according to timing and local protocol.', 'If no clear reversible cause or rejection is suspected, arrange urgent allograft biopsy through the transplant service.'], AMBER))
story += [P('5. Infection prevention and common timing patterns','H1x'),P('Risk reflects donor/recipient serostatus, intensity of immunosuppression, epidemiology and prophylaxis. Infection may present atypically because immunosuppression can blunt fever and inflammation.','Bodyx')]
story.append(tbl([
['Period after transplant','Common concerns'],
['0-1 month','Healthcare-associated and surgical infection, catheter-related urinary infection, wound infection, donor-derived infection.'],
['1-6 months','Opportunistic infections during greatest immunosuppression: CMV, Pneumocystis jirovecii, BK polyomavirus, fungal infection and reactivation infections.'],
['>6 months','Community-acquired infection; ongoing opportunistic disease if augmented immunosuppression or graft dysfunction. Urinary infection remains common.']
],[4.0*cm,13.0*cm]))
story.append(box('Prevention and alerts', ['Typical prophylaxis may include trimethoprim-sulfamethoxazole for Pneumocystis and CMV prevention tailored to donor/recipient serostatus. Duration varies by protocol and risk.', 'Avoid live vaccines after transplant. Give non-live vaccines according to transplant protocol, preferably optimize vaccines before transplantation.', 'Urgently assess fever, rigors, breathlessness, dysuria, diarrhoea, persistent headache, new rash, or reduced urine output.'], GREEN))
story += [P('6. Surgical, cardiovascular and metabolic complications','H1x')]
story.append(tbl([
['Domain','Examples and surveillance'],
['Surgical/urologic','Bleeding, lymphocele, wound complication, urinary leak or ureteric obstruction, vascular thrombosis/stenosis. Suspect with pain, swelling, falling urine output or abrupt graft dysfunction.'],
['Cardiovascular','Hypertension, diabetes, dyslipidaemia, weight gain and cardiovascular disease. Manage aggressively with lifestyle measures and individualized pharmacotherapy.'],
['Drug-related','CNI nephrotoxicity, tremor/neurotoxicity, hyperkalaemia, hypomagnesaemia; antimetabolite-related cytopenias/GI effects; steroid-related diabetes, osteoporosis and cataract; mTOR-related dyslipidaemia, proteinuria, oedema and impaired wound healing.'],
['Cancer','Higher risk of skin cancer, PTLD and some virus-associated cancers. Maintain screening, sun protection and a low threshold to investigate suspicious lesions or systemic symptoms.']
],[4.0*cm,13.0*cm]))
story.append(PageBreak())
story += [P('7. Long-term follow-up','H1x'),P('Follow-up frequency is highest early after transplant and becomes individualized once stable. Care is shared with the transplant team. Monitor graft function, blood pressure, cardiovascular risk, proteinuria, immunosuppressant exposure, infection surveillance, cancer screening, bone-mineral health, reproductive health and mental well-being.','Bodyx')]
story.append(tbl([
['Every review','Periodically / as indicated'],
['Symptoms, adherence and adverse effects<br/>Blood pressure, weight, oedema and volume status<br/>Creatinine/eGFR, electrolytes, glucose and drug level where applicable<br/>Urinalysis and proteinuria assessment','Blood count, lipid profile, HbA1c/diabetes assessment<br/>Calcium, phosphate, PTH and vitamin D assessment<br/>BK and CMV surveillance per protocol/risk<br/>Skin examination, age-appropriate cancer screening<br/>Vaccination review and bone health assessment']
],[8.5*cm,8.5*cm]))
story += [P('8. Special situations','H1x')]
story.append(tbl([
['Situation','Key point'],
['Recurrent kidney disease','Disease-specific recurrence is possible, such as focal segmental glomerulosclerosis, membranous nephropathy, IgA nephropathy, atypical haemolytic uraemic syndrome or primary hyperoxaluria. Define recurrence risk before transplant and monitor targeted markers.'],
['Pregnancy','Plan with transplant and maternal-fetal medicine teams. Avoid teratogenic immunosuppressants such as mycophenolate before conception. Evaluate graft stability, blood pressure, proteinuria and infection.'],
['BK polyomavirus','Often detected through protocol viral-load screening. Management commonly begins with carefully reduced immunosuppression under specialist direction, balancing viral clearance against rejection risk.'],
['Malignancy / PTLD','Evaluate promptly. Management may include reduction of immunosuppression and disease-specific oncologic/hematologic treatment directed by specialists.']
],[4.0*cm,13.0*cm]))
story += [P('Patient red flags: seek urgent transplant-team advice','H1x'),P('Fever or rigors; sudden fall in urine output; new graft-site pain/swelling; persistent vomiting or diarrhoea; shortness of breath; chest pain; severe headache/neurologic symptoms; rapidly rising blood pressure; inability to take immunosuppression; or a missed dose with uncertainty about what to do.','Call')]
story += [P('Selected references','H1x'),P('1. KDIGO Transplant Work Group. <i>Clinical Practice Guideline for the Care of Kidney Transplant Recipients.</i> Am J Transplant. 2009;9(Suppl 3):S1-S157. The guideline remains a major reference but local protocols and newer evidence may update individual practices.<br/>2. KDIGO. <i>Clinical Practice Guideline on the Evaluation and Care of Living Kidney Donors.</i> 2017.<br/>3. Sabiston Textbook of Surgery, kidney transplant operation section.<br/>4. Comprehensive Clinical Nephrology, 7th ed., kidney transplant dysfunction and biopsy sections.<br/>5. Ortved M, et al. Early surgical complications following kidney transplantation in adults: a systematic review. <i>Transplant Rev.</i> 2025. PMID: 40912061.','Small')]
story.append(Spacer(1,5)); story.append(P('Version: 2 October 2026. This document is educational and does not replace assessment by a transplant professional.','Small'))
doc.build(story,onFirstPage=header_footer,onLaterPages=header_footer)
print(OUT)
python "/tmp/workspace/renal-transplant-quick-reference/src/create_pdf.py" && python -c "from pypdf import PdfReader; p='/tmp/workspace/renal-transplant-quick-reference/output/Renal_Transplantation_Quick_Reference.pdf'; r=PdfReader(p); print('pages=',len(r.pages)); print('size=',__import__('os').path.getsize(p)); print(r.pages[0].extract_text()[:300])"
python -c "import fitz; p='/tmp/workspace/renal-transplant-quick-reference/output/Renal_Transplantation_Quick_Reference.pdf'; d=fitz.open(p); pix=d[0].get_pixmap(matrix=fitz.Matrix(1.4,1.4), alpha=False); pix.save('/tmp/workspace/renal-transplant-quick-reference/output/page1_preview.png'); print('rendered', pix.width, pix.height)"
python -c "from pypdf import PdfReader; import os; p='/tmp/workspace/renal-transplant-quick-reference/output/Renal_Transplantation_Quick_Reference.pdf'; r=PdfReader(p); txt=''.join(page.extract_text() or '' for page in r.pages); required=['RENAL TRANSPLANTATION','Immunosuppression','Rejection','Long-term follow-up','Selected references']; missing=[x for x in required if x not in txt]; print({'exists':os.path.isfile(p),'bytes':os.path.getsize(p),'pages':len(r.pages),'missing_required':missing,'encrypted':r.is_encrypted})"
Renal Transplantation Quick Reference
PDF Document · PDF