OpenLLM-France/wikimedia huggingface dataset:
# Radiation Oncology/Palliation/Palliation Overview

* Front Page: Radiation Oncology | RTOG Trials | Randomized Trials

## General review

* Hoegler - PMID 9202888 — "Radiotherapy for palliation of symptoms in incurable cancer." Hoegler D. Curr Probl Cancer. 1997 May-Jun;21(3):129-83.
** Nice abstract. Discusses hemi-body radiotherapy.

## Palliative Prognostic (PaP) Score

* Best validated and most widely used predictive scoring system
* Endorsed by European Association for Palliative Care
* Milan; 1999 (Italy) PMID 10203875 -- "A new palliative prognostic score: a first step for the staging of terminally ill cancer patients. Italian Multicenter and Study Group on Palliative Care." (Pirovano M, J Pain Symptom Manage. 1999 Apr;17(4):231-9.)
** Model developed for survival in terminally ill cancer patients
** Variables (total tally)
*** Dyspnea: no (0) vs yes (1)
*** Anorexia: no (0) vs yes (1.5)
*** KPS: >=30 (0) vs. 10-20 (2.5)
*** CPS (clinical prediction of survival, in weeks): 11-12 (2.0) vs. 7-10 (2.5) vs. 5-6 (4.5) vs 3-4 (6.0) vs. 1-2 (8.5)
*** WBC: <8.5K (0) vs. 8.5-11K (0.5) vs. >11K (1.5)
*** Lymphocyte percentage: 20-40% (0) vs. 12-20% (1.0) vs. <12% (2.5)
** Risk groups (30-day survival probability):
*** Score 0-5.5: >70%
*** Score 5.6-11: 30-70%
*** Score 11-17.5: <30%

## Hemibody Irradiation

* RTOG 8206 -- Local RT + hemibody RT vs Local RT + observation
** Randomized. 499 patients with painful body metastases, treated with standard palliative RT 30/10 to symptomatic site, then Arm 1) hemibody irradiation 8/1 (local site shielded, lungs max 7 Gy) vs Arm 2) no further treatment
** 1992 PMID 1374061 -- "A report of RTOG 8206: a phase III study of whether the addition of single dose hemibody irradiation to standard fractionated local field irradiation is more effective than local field irradiation alone in the treatment of symptomatic osseous metastases." (Poulter CA, Int J Radiat Oncol Biol Phys. 1992;23(1):207-14.)
*** Outcome: 1-year retreatment rate HBI 60% vs OBS 76%; 1-year disease progression HBI 35% vs OBS 46%
*** Toxicity: 5-15%
*** Conclusion: Hemibody irradiation can treat systemic and occult mets
* RTOG 78-10; 1981 (1978-1980) PMID 6169699 -- "Single-dose half-body irradiation for the palliation of multiple bone metastases from solid tumors: a preliminary report." (Salazar OM, Int J Radiat Oncol Biol Phys. 1981 Jun;7(6):773-81.)
** Prospective, dose-escalation. 91 patients (mostly breast, prostate, lung), significant cancer pain. Treated with upper hemibody irradiation (UHBI: above head to bottom of L4), midbody irradiation (MBI: top of diaphgram to bottom of obturator foramina), or lower hemibody irradiation (bottom of L4 to mid-ankles). Doses UHBI 6/1 -> 7/1 -> 8/1, and MBI/LHBI 8/1 -> 9/1 -> 10/1. Dose-rate 15-45 rad/min. Protection for eyes, mouth, parotids and lungs.
** Outcome: Pain relief 77% (complete 21%); within 48 hours in 50%
** Toxicity: Grade 3-4 nausea/vomiting/diarrhea in 12%, minimal with 8/1 more significant with 10/1
** Conclusion: 6/1 insufficient, 8/1 effective, no benefit for further increase. Results comparable to conventional 30/1
# ROSE Compiler Framework/How to add a ROSE commandline option

Often a feature added into ROSE comes with a set of command line options. These options can enable and customize the feature.
For example, the OpenMP support in ROSE is disabled by default. A special option is need to enable it. Also, the support can be as little as simply parsing the OpenMP directive or as complex as translating into multithreaded code.
This HOWTO quickly go through key steps to add options.

### internal flags

Options need to be stored somewhere. There are several choices for the storage,
* as a data member of SgProject , if the optiona is applicable to all files associated with a SgProject
* as a data member of SgFile, if the option is applicable to a single source file, or
* a member variable in a namespace you define, if the option is for some transformation or analysis.
If the option can be as specific as per file, it is recommended to add a new data member to SgFile to save the option value.
For example, here is a command line option to turn on the UPC language support:
ROSE/src/ROSETTA/src/support.C // add a date member for SgFile
ROSETTA process this information to automatically generate a member and the corresponding member access functions (set/get_member).

### process the option

Command line options should be handled within src/frontend/SageIII/sage_support/cmdline.cpp .
File level options are handled by void SgFile::processRoseCommandLineOptions ( vector<string> & argv )
Example code for processing the -rose:openmp option
ROSE commandline options should be removed after being processed, to avoid confusing the backend compiler
SgFile::stripRoseCommandLineOptions ( vector<string>& argv ) should have the code to strip off the option.

### use the option

In your code, you can use the automatically generated access functions to set/retrieve the stored option values.
For example

### document the option

Any option should be explained by the online help output.
Please add brief help text for your option in void SgFile::usage ( int status ) of ./src/frontend/SageIII/sage_support/cmdline.cpp:
# ROSE Compiler Framework/How to fix a bug

If you are trying to fix a bug ( your own or a bug assigned to you to fix). Here are high level steps to do the work

### Reproduce the bug

You can only fix a bug when you can reproduce it. This step may be more difficult than it sounds. In order to reproduce a bug, you have to
* find a proper input file
* find a proper translator: a translator shipped with ROSE is easy to find. But be patient and sincere when you ask for a translator written by users.
* find a similar/identical software and hardware environment: a bug may only appear on a specific platform when a specific software configuration is used
Possible results for this step:
* You can reproduce the bug reliably. Bingo! Go to the next step.
* You cannot reproduce the bug. Either the bug report is invalid or you have to keep trying.
* You can reproduce the bug once a while (random errors). Oops. This is kind of difficult situation.

### Find causes of the bug

Once you can reproduce the bug. You have to identify the root cause of the bug using a debugger like gdb.
Common steps involved
* simplify the input code as much as possible: It can be very hard to debug a problem with a huge input. Always try to prepare the simplest possible code which can just trigger the bug.
** Often, you have to use a binary search approach to narrow down the input code: only use half of the input at a time to try. Recursively cut the input file into two parts until no further cut is possible while you can still trigger the bug.
* forward tracking: for the translator, it usually takes input and generate intermediate results before the final output is generated. Using a debugger to set break points at each critical stages of the code to check if the intermediate results are what you expect.
* backwards tracking: similar to the previous techniques. But you just back tracking the problem.

### Fix the bug

Any bug fix commit should contain
* a regression test: so make check rules can make sure the bug is actually fixed and no further code changes will make the bug relapse.
# ROSE Compiler Framework/How to create a cross-language translator

In this HOW-to, it presents the steps of generating a cross-language translator. We will use Fortran to C translator as an example here.

### Change the sourcefile information

   * change the output file name. The suffix name has to be changed with this following function.
   * change the output language type.
   * Set the output to be target-language only.

### Identify language-dependent AST node

   * Example: ROSE AST uses different AST nodes to present a loop in C and Fortran. The following two figures represent the same loop for different languages.
    C uses SgForStatement for the for loops.
    C SgForStatement
    Fortran uses SgFortranDo for the do loops.
    Fortran SgFortranDo

### Implement the translation functions

   * Use the wholeAST as reference to implement the translation function.
   * Generate the new AST node by copy required information from the original AST node.
   * Remove the original node, and make sure the parent/child relationship in AST is setup properly.

### Testing output code

   * If compiler is available to test the output code, run the backend to generate object by the backend compiler.
   * If compiler is not available for the target language, make sure output codes can be generated from the testing cases. It is suggested to run the compilation tests for all the testing output.
# ROSE Compiler Framework/How to incrementally work on a project

Developing a big, sophisticated project entails many challenges. To mitigate some of these challenges, we have adopted several best practices: incremental development, code review, and continuous integration.
Here are some tips on how to divide up a big project into smaller, bite-sized pieces so each piece can be incrementally developed, code reviewed, and integrated.
* Input: define different sets of test inputs based on complexity and difficulty. Tackle simpler sets first.
* Output: define intermediate results leading to the final output. Often, results A and B are needed to generate C. So the project can have multiple stages, based on the intermediate results.
* Algorithm: complex compiler algorithms are often just enhanced versions of more fundamental algorithms. Implement the fundamental algorithms first to gain insight and experience. Then, afterward, you can implement the full-blown versions.
* Language: for projects dealing with multiple languages, focus on one language at a time.
* Platform: limit the scope of supported platforms: Linux, Ubuntu, OS X (TODO: add reference to ROSE supported platforms)
* Performance: Start with a basic, working implementation first. Then try to optimize its performance, efficiency.
* Scope: your translator could first focus on working at a function scope, then grow to handle an entire source file, or even multiple files, at the same time.
* Skeleton then meat: a project should be created with the major components defined first. Each component can be enriched separately later on.
* Annotations (manual vs. automated): Performing one compiler task often requires results from many other tasks being developed. Defining source code annotations as the interface between two tasks can decouple these dependencies in a clean manner. The annotations can be first manually inserted. Later the annotations can be automatically generated by the finished analysis.
* Optional vs. Default: introducing a flag to turn on/off your feature. Make it as a default option when it matures.
# Radiation Oncology/RTOG Trials/9019

* Front Page: Radiation Oncology | RTOG Trials | Randomized Trials
RTOG 90-19 (PROSTATE)
* Link to textbook
* This is a SWOG-8794 Study (INT-0086, CALGB-9493, EST-9887)
* Title: A Phase III Study of the Treatment of Pathologic Stage C Carcinoma of the Prostate With Adjuvant Radiotherapy
* Objectives:
** (1) To compare the disease-free survival rates in completely resected patients with pathologic stage C (T3N0M0) carcinoma of the prostate assigned to be treated with adjuvant external beam radiotherapy to that in patients assigned to receive no adjuvant therapy
** (2) To assess the qualitative and quantitative toxicities of patients with pathologic stage C (T3N0M0) carcinoma of the prostate when treated with external beam radiotherapy.
* Protocol:
** Arm 1: Radical Prostatectomy
** Arm 2: Radical Prostatectomy + 60-64 Gy EBRT
* Eligibility: Status Post RP, +ECE or +SVI or +SM, N0M0
* Activation: August 15, 1988 (RTOG Activation: April 20, 1992)
* Closed: January 1, 1997
* Publications:
** 2007 PMID 17538167 -- "Predominant treatment failure in postprostatectomy patients is local: analysis of patterns of treatment failure in SWOG 8794." (Swanson GP, J Clin Oncol. 2007 Jun 1;25(16):2225-9.) Conclusion: Failure in high risk patients predominately local; adjuvant RT reduces risk of failure
** 2006 PMID 17105795 — "Adjuvant radiotherapy for pathologically advanced prostate cancer: a randomized clinical trial." (Thompson IM Jr et al. JAMA. 2006 Nov 15;296(19):2329-35.) Conclusion: Adjuvant radiotherapy resulted in significantly reduced risk of PSA relapse and disease recurrence, although the improvements in metastasis-free survival and overall survival were not statistically significant.
** 2005 ASTRO Abstract Plenary #1, 2005 Webcast - "Phase III Randomized Study of Adjuvant Radiation Therapy versus Observation in Patients with Pathologic T3 Prostate Cancer (SWOG 8794)" Swanson GP et al. IJROBP Volume 63, Supplement 1 , 1 October 2005, Page S1.
** 1994 No Abstract -- "An opportunity to determine optimal treatment of pT3 prostate cancer: the window may be closing." (Thompson IM, Urology 1994). Review
** 1992 -- "Adjuvant Radiotherapy Following Radical Prostatectomy for Pathologic Stage C Adenocarcinoma of the Prostate: Initial Evaluation of Toxicity." I Thompson, ED Crawford, G Miller, J Paradelo, B Blumenstein, M Wolf, C Moinpour, K Hayden. American Society of Clinical Oncology 11:212 (#663), 1992.
# Radiation Oncology/RTOG Trials/9408

* Front Page: Radiation Oncology | RTOG Trials | Randomized Trials
RTOG 94-08 (PROSTATE)
* Title: A Phase III Trial of the Study of Endocrine Therapy Used As a Cytoreductive and Cytostatic Agent Prior to Radiation Therapy In Good Prognosis Locally Confined Adenocarcinoma of the Prostate
* Objective: To evaluate the potential impact of a combination of Zoladex and Flutamide used as cytoreductive agents prior to undergoing definitive radiation therapy in locally confined carcinomas of the prostate.
* Protocol:
** Arm 1: Neoadjuvant TAS 2 months before and during 66.6 Gy RT
** Arm 2: 66.6 Gy RT Alone
* Eligibility: cT1b-T2b, PSA <20, N0M0
* Enroll Target: 1980
* Activation: October 31, 1994
* Closed: April 30, 2001
* Publications:
** ASTRO 2009 - Plenary (Late Breaking; unpublished abstract) - Short term androgen deprivation prior to and during radiation therapy improves overall survival in patients with t1b-t2b adenocarcinoma of the prostate and PSA ≤ 20: initial results of RTOG 94-08 (Christopher Jones)
** Bruner D, Scott C, McGowan D, et al.: Validation of the sexual adjustment questionnaire (SAQ) in prostate cancer patients enrolled on Radiation Therapy Oncology Group studies 90-20 and 94-08. International Journal of Radiation Oncology, Biology, Physics 42(suppl 1): A156, 202, 1998.
** Bruner D, Scott C, McGowan, et al.: Factors influencing sexual outcomes in prostate cancer patients enrolled on radiation therapy oncology group studies 90-20 and 94-08. Proceedings of the International Society for Quality of Life Research 7: 575, 1998.
# Radiation Oncology/RTOG Trials/8823

* Front Page: Radiation Oncology | RTOG Trials | Randomized Trials
RTOG 88-23 (LIVER)
* Title: Phase I/II Study of Integrated Intra-Arterial CDDP and Intravenous I131-Antiferritin in the Treatment of Nonresectable Hepatocellular Cancer
* Objective:
** I. Determine the response rate and toxicity produced by combined intra-arterial cisplatin and intravenous I131-antiferritin in patients with unresectable hepatocellular cancer.
* Protocol:
** Induction Phase: Intravenous Cisplatin followed by EBRT
** Treatment Phase: Intra-arterial cisplatin + I-131-Antiferritin.
* Eligibility: hepatic metastases documented by liver scan
* Enrolled:
* Conclusion:
** PMID 9612600 -- Survival results among patients with alpha-fetoprotein-positive, unresectable hepatocellular carcinoma: analysis of three sequential treatments of the RTOG and Johns Hopkins Oncology Center. (Abrams RA, Cancer J Sci Am. 1998 May-Jun;4(3):178-84.) Conclusion: "Patients with unresectable alpha-fetoprotein-positive hepatocellular carcinoma experienced improved survival and decreased toxicity when managed with post-induction cycles of intra-arterial cisplatin as compared with intravenous doxorubicin and 5-FU. Intravenous 131I-polyclonal antiferritin did not improve survival when added to either post-induction regimen but dramatically increased hematologic toxicities."
* Publications:
# Radiation Oncology/RTOG Trials/8822

* Front Page: Radiation Oncology | RTOG Trials | Randomized Trials
RTOG 88-22 (PROSTATE, BREAST, PALLIATION)
* Title: Phase I/II Study of Fractionated Hemibody Irradiation to Treat Osseous Metastases in Patients with Primaries of the Breast or Prostate
* Objective:
** (1) Determine the hematologic and acute nonhematologic toxicity of fractionated hemibody irradiation in the treatment of osseous metastases in patients with primaries of the breast or prostate.
** (2) Establish the maximum tolerated dose of fractionated hemibody irradiation in this patient population.
** (3) Study the delay of new metastases and the progression of existing asymptomatic metastases as a function of the treatment field.
* NCI_Protocol: Fractionated hemibody irradiation plus local-field irradiation with electron beams
** 30 Gy in 10 fraction followed by escalating doses of HBI (2.5 Gy/fx):
** Arm 1: HBI 10.0 Gy
** Arm 2: HBI 12.5 Gy
** Arm 3: HBI 15.0 Gy
** Arm 4: HBI 17.5 Gy
** Arm 5: HBI 20.0 Gy
* Eligibility:Primary breast or prostate CA, no spinal compression, pain/narcotic score 2
* Enrolled: 144 patients
* Publications:
** PMID 8823257 -- A phase I/II study to evaluate the effect of fractionated hemibody irradiation in the treatment of osseous metastases--RTOG 88-22. (Scarantino CW, IJRBOP 1996). Conclusion: "The maximum tolerated dose of fractionated (2.50 Gy) HBI was found to be 17.5 Gy. The major dose limiting toxicity was hematological (thromboleukopenia). There was not a significant dose response effect on occult disease (appearance of new disease) or in the requirement for additional treatment, although certain trends were noted for the higher doses. When only patients completing assigned HBI from RTOG 82-06 and 88-22 were compared, there was no difference in the time to new disease or additional treatment in the treated field. Based on the investigative parameters of this study, single high-dose HBI was as effective as fractionated HBI. The incorporation of cytokines, to ameliorate hematological toxicity, should allow for the delivery of higher doses of fractionated HBI and sequential HBI as a means of delivering systemic irradiation."
** Scarantino C, Caplan R, Rotman M, et al.: A phase I/II study to evalutate the effect of fractionated hemibody irradiation in the treatment of osseous bone metastases-RTOG 88-22. Int J Radiat Oncol Biol Phys 32(suppl 1): A52, 167, 1995.
# Programming Fundamentals/Data Types
## Overview

A data type is a classification of data which tells the compiler or interpreter how the programmer intends to use the data. Most programming languages support various types of data, including integer, real, character or string, and Boolean.

## Discussion

Our interactions (inputs and outputs) with a program are treated in many languages as a stream of bytes. These bytes represent data that can be interpreted as representing values that we understand. Additionally, within a program, we process this data in various ways such as adding them up or sorting them. This data comes in different forms. Examples include:
* your name – a string of characters
* your age – usually an integer
* the amount of money in your pocket – usually a value measured in dollars and cents (something with a fractional part)
A major part of understanding how to design and code programs is centered in understanding the types of data that we want to manipulate and how to manipulate that data.
Common data types include:
| Data Type | Represents | Examples |
| integer | whole numbers | -5, 0, 123 |
| floating point (real) | fractional numbers | -87.5, 0.0, 3.14159 |
| string | A sequence of characters | "Hello world!" |
| Boolean | logical true or false | true, false |
| nothing | no data | null |
The common data types usually exist in most programming languages and act or behave similarly from language to language. Additional complex and/or composite data types may exist and vary from language to language.

### Flowchart
## Key Terms
### Boolean

    A data type representing logical true or false.

### Data types

    Defines a set of values and a set of operations that can be applied on those values.

### Floating point

    A data type representing numbers with fractional parts.

### Integer

    A data type representing whole numbers.

### String

    A data type representing a sequence of characters.

## References

* cnx.org: Programming Fundamentals – A Modular Structured Approach using C++
* Flowgorithm – Flowchart Programming Language
# Programming Fundamentals/Displaying Array Members
## Overview

To display all array members, get the value of each element using a for loop and output the element using index notation and the loop control variable.

## Discussion
### Accessing Array Members

Let's say we want to create an integer array named "ages" with five values of 49, 48, 26, 19, and 16. In pseudocode, this might be written as:
Declare Integer Array ages[5]
Assign ages = [49, 48, 26, 19, 16]
To display all elements of the array in order, we might write:
Output ages[0]
Output ages[1]
Output ages[2]
Output ages[3]
Output ages[4]
While this works for short arrays, it is a terrible method for arrays that contain hundreds or thousands of values due to having to type out each element. One of the principles of software development is don’t repeat yourself (DRY). Violations of the DRY principle are typically referred to as WET solutions, which is commonly taken to stand for either “write everything twice”, “we enjoy typing” or “waste everyone’s time."
Rather than repeating ourselves, we can use a "for" loop to get the value of each element of the array and use the loop control variable as the array index. Consider the following pseudocode:
This approach is much more efficient from a programming perspective, and also results in a smaller program. But there is still one more opportunity for improvement. Most programming languages support a built-in method for determining the size of an array. To reduce potential errors and required maintenance, the loop control should be based on the size of the array rather than a hard-coded value. Consider:
This method allows for flexible coding. By writing the "for" loop in this fashion, we can change the declaration of the array by adding or subtracting members and we don’t need to change our for loop code.

## Key Terms
### don’t repeat yourself

    A principle of software development aimed at reducing repetition of software patterns, replacing repetition with abstractions, or repetition of the same data. Instead, programmers should use data normalization to avoid redundancy.

### flexible coding

    Using the size of an array to determine the number of loop iterations required.

## References

* cnx.org: Programming Fundamentals – A Modular Structured Approach using C++
* Wikiversity: Computer Programming
* ↑ Wikipedia: Don't repeat yourself
* ↑ Wikipedia: Don't repeat yourself
# Programming Fundamentals/Data and Operators
## Overview

This chapter introduces constants and variables, data types, and operators.

## Chapter Outline

* Constants and Variables
* Identifier Names
* Data Types
** Integer Data Type
** Floating-Point Data Type
** String Data Type
** Boolean Data Type
** Nothing Data Type
* Order of Operations
* Assignment
* Arithmetic Operators
* Integer Division and Modulus
* Unary Operations
* Lvalue and Rvalue
* Data Type Conversions
* Input-Process-Output Model
* Code Examples
** C++
** C#
** Java
** JavaScript
** Python
** Swift
* Practice: Data and Operators

## Learning Objectives

* Understand key terms and definitions.
* Understand basic data types and how operators manipulate data.
* Given example pseudocode, flowcharts, and source code, create a program that uses appropriate data types and operators to solve a given problem.