REE / tasks /bicycle_studio /instruction.md
zzqsb's picture
Release the REE tasks and dataset card.
7f50cd1
|
Raw History Blame Contribute Delete
18 kB

Bicycle Design Studio

Goal

This task uses a suite of bicycle design evaluators. A bicycle design team needs portfolios of designs tailored to a rider, a use case, and an aesthetic target. Write a general method that reads each supplied context and proposes candidate design vectors. The team's supplied evaluator defines both feasibility and performance; the team values portfolios covering complementary performance tradeoffs, measured by feasible hypervolume. You may query this evaluator and its gradients while developing and running your method.

What You Have

Path Contents
/app/methods/main/ Your editable submission, initially the starter; its entry point is run.sh.
/app/core/ The shared file interface, fixed trained evaluator, exemplar catalog, and metric. CORE_DIR=/app/core is set.
/app/data/ Practice inputs, with an instance in each subdirectory.
/app/selfcheck.py The rehearsal command described below.

The team supplies instance.json in each input directory. It is a JSON object containing context_a, context_b, context_c, and output_rows.

File term Meaning in the studio
context_a Rider dimensions in metres, ordered as below.
context_b A categorical indicator of the intended use case.
context_c A 512-dimensional aesthetic/text target embedding, with no additional implied semantic labels for its coordinates.
output_rows The number of candidate designs the team requests for this input.

The context_a vector has 6 components. The context_b vector has 3 components. Its entries encode the category as a one-hot indicator. The context_c vector has 512 components. Read the requested portfolio size from output_rows; do not hard-code it. The files and programmatic interface keep these exact keys; the tables below give their scientific meanings.

The rider components use the following zero-based order.

Component Meaning in the supplied evaluator Unit
context_a[0] Upper-leg length m
context_a[1] Lower-leg length m
context_a[2] Arm length m
context_a[3] Torso length m
context_a[4] Neck-and-head length in the aerodynamic proxy; also used as foot length by the ergonomics calculations m
context_a[5] Torso width m

The use-case components have this order.

context_b Use case
[1, 0, 0] Road cycling (road)
[0, 1, 0] Mountain biking (mtb)
[0, 0, 1] Commuting (commute)

Read os.environ["CORE_DIR"] to locate the shared code. Public resources include interface/api.py, interface/schema.json, interface/catalog.csv, engine/, and metric/metric.py under that directory. The catalog contains exemplar design vectors. The shared catalog and output CSV schema has 83 ordered columns, named p000 through p082. The schema defines the coordinate ordering, clipped columns, normalized groups, objective mask, and reference vector. The evaluator's code and weights determine the design calculations; no external model or service is needed.

The 83 design coordinates have the following meanings. BB denotes bottom bracket; tube diameters are outer diameters. Numeric type classes retain the original source class numbers where the supplied core does not name a subtype. OHCLASS denotes a categorical coordinate; its value is a category weight under the evaluator's relaxation. The units and coding describe the fields, without changing the allowed submitted values.

Column Original field Meaning Unit / coding
p000 Seatpost LENGTH Seatpost length mm
p001 CS textfield Chain-stay length mm
p002 BB textfield Bottom-bracket drop mm
p003 Stack Frame stack mm
p004 Head angle Head-tube angle degrees
p005 Head tube length textfield Head-tube length mm
p006 Seat stay junction0 Seat-stay junction offset mm
p007 Seat tube length Seat-tube length mm
p008 Seat angle Seat-tube angle degrees
p009 DT Length Down-tube length mm
p010 FORK0R Fork offset/rake mm
p011 BB diameter Bottom-bracket outer diameter mm
p012 ttd Top-tube outer diameter mm
p013 dtd Down-tube outer diameter mm
p014 csd Chain-stay outer diameter mm
p015 std Seat-tube outer diameter mm
p016 htd Head-tube outer diameter mm
p017 ssd Seat-stay outer diameter mm
p018 Chain stay position on BB Chain-stay position on bottom bracket mm
p019 SSTopZOFFSET Seat-stay top Z-offset mm
p020 Head tube upper extension2 Head-tube upper extension mm
p021 Seat tube extension2 Seat-tube extension mm
p022 Head tube lower extension2 Head-tube lower extension mm
p023 SEATSTAYbrdgshift Seat-stay bridge offset mm
p024 CHAINSTAYbrdgshift Chain-stay bridge offset mm
p025 SEATSTAYbrdgdia1 Seat-stay bridge diameter mm
p026 CHAINSTAYbrdgdia1 Chain-stay bridge diameter mm
p027 SEATSTAYbrdgCheck Seat-stay bridge inclusion dimensionless indicator
p028 CHAINSTAYbrdgCheck Chain-stay bridge inclusion dimensionless indicator
p029 Dropout spacing Rear dropout spacing mm
p030 Wall thickness Bottom Bracket Bottom-bracket wall thickness mm
p031 Wall thickness Top tube Top-tube wall thickness mm
p032 Wall thickness Head tube Head-tube wall thickness mm
p033 Wall thickness Down tube Down-tube wall thickness mm
p034 Wall thickness Chain stay Chain-stay wall thickness mm
p035 Wall thickness Seat stay Seat-stay wall thickness mm
p036 Wall thickness Seat tube Seat-tube wall thickness mm
p037 Wheel diameter front Front-wheel diameter mm
p038 RDBSD Rear-wheel radial depth parameter mm
p039 Wheel diameter rear Rear-wheel diameter mm
p040 FDBSD Front-wheel radial depth parameter mm
p041 BB length Bottom-bracket length mm
p042 Wheel cut Rear-wheel cutout diameter mm
p043 BELTorCHAIN Belt/chain selection dimensionless; source 0/1 coding
p044 Number of cogs Number of rear cogs count
p045 Number of chainrings Number of front chainrings count
p046 FIRST color R_RGB Primary frame color, red channel RGB intensity, 0–255 scale
p047 FIRST color G_RGB Primary frame color, green channel RGB intensity, 0–255 scale
p048 FIRST color B_RGB Primary frame color, blue channel RGB intensity, 0–255 scale
p049 SPOKES composite front Front composite-spoke setting dimensionless source setting
p050 SPOKES composite rear Rear composite-spoke setting dimensionless source setting
p051 SBLADEW front Front spoke-blade width setting unit not specified in the supplied core
p052 SBLADEW rear Rear spoke-blade width setting unit not specified in the supplied core
p053 Saddle length Saddle length mm
p054 Saddle height Saddle height mm
p055 MATERIAL OHCLASS: ALUMINIUM MATERIAL, class ALUMINIUM dimensionless category weight
p056 MATERIAL OHCLASS: STEEL MATERIAL, class STEEL dimensionless category weight
p057 MATERIAL OHCLASS: TITANIUM MATERIAL, class TITANIUM dimensionless category weight
p058 Head tube type OHCLASS: 0 Head tube type, class 0 dimensionless category weight
p059 Head tube type OHCLASS: 1 Head tube type, class 1 dimensionless category weight
p060 Head tube type OHCLASS: 2 Head tube type, class 2 dimensionless category weight
p061 Head tube type OHCLASS: 3 Head tube type, class 3 dimensionless category weight
p062 Down tube type OHCLASS: 0 Down tube type, class 0 dimensionless category weight
p063 Down tube type OHCLASS: 1 Down tube type, class 1 dimensionless category weight
p064 Down tube type OHCLASS: 2 Down tube type, class 2 dimensionless category weight
p065 RIM_STYLE front OHCLASS: DISC RIM_STYLE front, class DISC dimensionless category weight
p066 RIM_STYLE front OHCLASS: SPOKED RIM_STYLE front, class SPOKED dimensionless category weight
p067 RIM_STYLE front OHCLASS: TRISPOKE RIM_STYLE front, class TRISPOKE dimensionless category weight
p068 RIM_STYLE rear OHCLASS: DISC RIM_STYLE rear, class DISC dimensionless category weight
p069 RIM_STYLE rear OHCLASS: SPOKED RIM_STYLE rear, class SPOKED dimensionless category weight
p070 RIM_STYLE rear OHCLASS: TRISPOKE RIM_STYLE rear, class TRISPOKE dimensionless category weight
p071 Handlebar style OHCLASS: 0 Handlebar style, class 0 (road/drop bar) dimensionless category weight
p072 Handlebar style OHCLASS: 1 Handlebar style, class 1 (mountain bar) dimensionless category weight
p073 Handlebar style OHCLASS: 2 Handlebar style, class 2 (bullhorn bar) dimensionless category weight
p074 Stem kind OHCLASS: 0 Stem kind, class 0 dimensionless category weight
p075 Stem kind OHCLASS: 1 Stem kind, class 1 dimensionless category weight
p076 Stem kind OHCLASS: 2 Stem kind, class 2 dimensionless category weight
p077 Fork type OHCLASS: 0 Fork type, class 0 dimensionless category weight
p078 Fork type OHCLASS: 1 Fork type, class 1 dimensionless category weight
p079 Fork type OHCLASS: 2 Fork type, class 2 dimensionless category weight
p080 Seat tube type OHCLASS: 0 Seat-tube type, class 0 (aero) dimensionless category weight
p081 Seat tube type OHCLASS: 1 Seat tube type, class 1 dimensionless category weight
p082 Seat tube type OHCLASS: 2 Seat tube type, class 2 dimensionless category weight

The interface provides read_instance(data) for the JSON object and float32 context tensors, read_catalog() for exemplar vectors, and interface.api.evaluate_tensor(x, context) for differentiable evaluation. For a batch, the tensor shapes are x: (N, 83) and evaluation: (N, 50). OBJECTIVE_MASK selects the objectives to minimize; its complement selects constraint residuals. REFERENCE gives the positive objective reference coordinates. write_output(output, x) writes the required CSV. Complete synthetic input and output examples are available at interface/examples/instance.json and interface/examples/candidates.csv under the core directory.

The 50 evaluation coordinates have the following zero-based indices. All 10 objectives are minimized:

Evaluation index Objective name
0 Usability Score
1 Drag Force (N)
2 Knee Angle Error (deg.)
3 Hip Angle Error (deg.)
4 Arm Angle Error (deg.)
11 Cosine Distance To Embedding
12 Mass (kg)
13 Planar Compliance Score
14 Transverse Compliance Score
15 Eccentric Compliance Score

The remaining 40 coordinates are constraint residuals:

Evaluation index Constraint residual name
5 Arm Too Long for Bike
6 Saddle Too Far From Handle
7 Torso Too Long for Bike
8 Saddle Too Far From Crank
9 Upper Leg Too Long for Bike
10 Lower Leg Too Long for Bike
16 Planar Safety Factor
17 Eccentric Safety Factor
18 Predicted Frame Validity
19 Saddle Height Too Small
20 Saddle Collides With Seat Tube
21 Saddle Too Short
22 Head Angle Over Limit
23 Seat Angle Over Limit
24 Seat Post Too Short
25 Seat Post Too Long
26 Rear Wheel Inner Diameter Too Small
27 Front Wheel Inner Diameter Too Small
28 Seat Tube Extension Longer Than Seat Tube
29 Head Tube Upper Extension And Lower Extension Overlap
30 Seat Stay Junction Longer Than Seat Tube
31 Non-negative Parameter Is Negative
32 Chain Stay Smaller Than Rear Wheel Radius
33 Chain Stay Shorter Than BB Drop
34 Seat Stay Smaller Than Rear Wheel Radius
35 Seat Tube Collides With Rear Wheel
36 Down Tube Can't Reach Head Tube
37 Rear Wheel Cutout Severs Seat Tube
38 Foot Collides With Front Wheel
39 Crank Hits Ground In Lowest Position
40 RGB Value Greater Than 255
41 Chain Stays Intersect
42 Tube Wall Thickness Exceeds Radius
43 Seat Tube Too Narrow For Seat Post
44 Down Tube Improperly Joins Head Tube
45 Top Tube Improperly Joins Head Tube
46 Top Tube Improperly Joins Seat Tube
47 Down Tube Collides With Front Wheel
48 Saddle Hits Top Tube
49 Saddle Hits Head Tube

The returned Usability Score is one minus the predicted usability, clipped to [0, 1], and Cosine Distance To Embedding is half of one minus cosine similarity. The Planar Safety Factor and Eccentric Safety Factor residuals are one minus the corresponding nonnegative predicted factors; the Predicted Frame Validity residual is the model prediction minus 0.5. The supplied evaluator defines the other residuals and their scales.

The evaluators combine fixed learned proxy models for usability, aerodynamic drag, aesthetics, structural performance and frame validity with geometric and ergonomic calculations. These are model evaluations, not physical tests. The continuous categorical relaxation accepts mixed and all-zero groups as described below; scored feasibility does not certify that a bicycle is physically buildable.

What You Submit

Submit a general method in /app/methods/main/. The studio's grading service carries only that directory into a clean container with the same installed core. Keep every trained model, helper program, and other artifact your method needs under that directory. Session files created elsewhere do not carry over.

The grader calls run.sh <data dir> <output dir> once per instance, as an unprivileged account. Your method must read the provided input directory, which is read-only, and write candidates.csv into the supplied output directory. Use the exact ordered header from interface/schema.json and exactly output_rows data rows. Each row is a candidate design vector. Every coordinate is an arbitrary finite real value representable as float32. The exemplar catalog's observed ranges do not bound submitted coordinates. Duplicate candidate rows are valid.

The service requires each output to be a regular text file no larger than 64 MB. If you add /app/methods/main/build.sh, the service runs it once, offline, before any instance, with a 900-second limit. A build failure fails the entire submission. The starter writes zero vectors of the requested shape; replace or extend it as you choose.

Feasibility Before Cost

The design team's evaluator first applies clip(x_j, 0, 1) to the coordinates listed as bounded_columns in interface/schema.json. For each listed group, it divides coordinates by max(group_sum, 1e-8); a zero group remains zero. Mixed groups are not rounded into categorical choices. The supplied tensor evaluator computes the objectives and residuals from these transformed coordinates and the context.

The team counts a candidate as feasible exactly when every constraint residual satisfies g_j <= 0. A NaN residual fails this comparison. Infeasible candidates contribute no hypervolume, regardless of their objective values. An otherwise valid portfolio with no feasible candidates has HV = 0; this is distinct from a malformed submission.

Budget

The work session is 4 CPUs, 16 GB RAM, and 12 hours, with no network access.

The grading service runs each method call with 4 CPUs, 8 GB RAM, no network access, and a 60-second limit. It passes this budget as TASK_BUDGET_SEC (60 seconds). Keep computation and thread counts within those resources and allow time to write the output. The service kills a method still running at the deadline and any process left running after its entry returns; either event fails that instance.

The session and grading each have 10 GB of storage.

How It Is Judged

The studio evaluates 80 sealed instances, available only in the grading container. It uses the public evaluator and metric, with no private labels or hidden answer files.

For each feasible candidate, let f_j be its objective values and r_j the positive reference coordinates. The metric replaces each NaN objective with its corresponding reference value cast to float32, then discards rows with any remaining non-finite objective. It normalizes each remaining coordinate as z_j = clip(f_j, 0, r_j) / r_j. The portfolio score is HV = volume(union_i product_j [z_ij, 1]) over feasible retained rows. Duplicate rows do not add volume. Higher hypervolume is better.

The official score is the arithmetic mean of the sealed instance scores, in the metric's own units. The failure score is -1. The grader assigns it for a missing or malformed output, incorrect header or shape, non-finite submitted coordinates, process failure, timeout, or a process left running. A failed build assigns that failure value to every sealed instance. The metric is implemented in metric/metric.py; from the installed core directory its command is python3 metric/metric.py --data <data dir> --output <output dir>, and its first stdout line is the score.

Self-check

Run python3 /app/selfcheck.py rehearse. The studio's rehearsal executes the current method on every practice input under grading conditions, including the unprivileged account, optional offline build, runtime limit, file checks, and public metric. Its last line is {"score": ...}, the arithmetic mean of the practice scores. This is a development smoke test, not the sealed score. The team requires the file and runtime contract, without prescribing an algorithm.