Giter Club home page Giter Club logo

swiml's People

Contributors

bartneck avatar calloc262 avatar clo0868 avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

swiml's Issues

continue element inconsistencies

The new continue element has some issues. I uploaded a test XML file and converted it to HTML. the comments in the XML describe what is going wrong: tests/continueTest/continueTest.xml.

SCR-20230809-lrx

Index file

Currently the training program index for a club needs to be created manually. This can be automated by checking all xml files in a directory and creating a new index XML file which in turn can be converted to HTML using XSLT.

Block instructions

It would be possible to move the elements of into the , element. Instead of writing.

In the folder bookExamples, the file repetitionBlockInstructions.xml has valid and invalid test cases.

Length tag rework

rewriting the length tag to be inside the instruction group and to have an enclosing length tag

XML schema versioning

We have to find a solution for publishing different versions of the same swiML.xsd schema. The old XML files still need to validate against the v1.0 while new XML files should validate against our upcoming 2.0 version. Do we need a different file with a new file name or is this handled inside the XML with the version tag?

CSS types

Create different CSS files depending on output (A4, 11cm for book, Screen). Have an XML element to set the desired output type.

Simplified repetition bold formatting

When using more than "1" repetition in a simplified repetition, the counter is not bold. Compare the 1 to the 2. This is part of JasiMasters2024020401.xml

SCR-20240206-obpo

SegmentName

The <segmentName> element can currently occur within any <repetition> or <instruction>. This makes no sense. It should only be allowed at the top level, right under the first element. In the folder bookExamples, the file segmentName.xml has valid and invalid test cases.

Instructions in Repetitions and Continues

Adding functionality so that any element in the instruction group can be added to containers such that any instructions within the container have the ability to inherit the instruction elements

Intensity within <repetition>

The <intensity><dynamicAcross>true</dynamicAcross></intensity> only makes sense within a <repetition> element. You proposed a new model of <intensity> that is split between <repetition> and <instruction>.

We need an assertion that intensity is always uniquely defined. We have to avoid that there is intensity in the repetition element and in the nested instruction element.

O name space

change "o" namespace to "sw" and change the URL to github as before.

PDF Conversion

At this point there is no direct way to produce a PDF from the XML files using XSLT. The only option right now is to translate the XML to HTML and then use a web browser to create the PDF manually. Alternatively, the XSL-FO language or Oxygen’s PDF Chemistry can be used to directly generate a PDF file.

operation of excludeAlign

The functionality of <excludeAlign> is a bit unclear and needs to be better described in the documentation. In the JasiMasters2024012101.xml file, there are several alignment issues. Using the element does not seem to help with the line break of the intensity.

SCR-20240202-krao

Name space

We have to sort out the proper name space approach to overcome the issues that Callum is having with his branch.

Parameterisation

The program needs to adjust to individual speeds. Fast swimmers need to swim more within one hour while slower swimmers less. This should be based on best times, which then creates 70% etc.

Continue Element

The swiML schema currently has no means to express a continue swimming block. The coach might write 300 FR KDS which is 100 FR Kick, 100 FR Drill, 100 FR Swim. Right now this would be expressed by setting the rest period for these three instructions to zero. We need a dedicated <continue> XML element for this purpose. This would be similar to how a <repetition> is currently setup. There will be more blocks like this in the future, such as <pyramid>. In the folder bookExamples, the file continue.xml has valid and invalid test cases.

The length of the <continue> block needs to be calculated through XSLT. Neither the coach nor Python should do this calculation. We need to avoid the coaches entering invalid information.

The <continue> block should have a summary on the left in the HTML/CSS. This summary can be either the sum of the length of the included <instructions> or a <numberOfContinueInstructions>. The later is not a good name and we still need to find a better name. It is currently called <simplify> which is too generic.

alignment of repetition and continue

At times the intend of repetition and continue are too far apart. This causes layout options. The solution would be:

  • limit scope to segment
  • manually set flag to include/exclude
  • if intends are too different then don't
  • look two up/down and only align with those.

club id

assert that id in club index is unique

Exact PDF scaling

The book in which the PDF files will be embedded is exactly 11 cm wide. It would be great to be able to consistently scale all swiML PDF output to fit into a maximum of 11 cm widths. The title and author are currently centered and they should be centered to a specific value, such as 11cm. The display of the current HTML output can be scaled by the browser. Hence the resulting PDF could have smaller or bigger text. This is undesirable. All text should be consistent in size.

vikings programs

Create a list of the programs from the Viking club using the swimTraining.xsd

XSLT updates

a lot of the xsl got left out of the updates done already
gonna add it all to this instead of trying to redo every issues with separate xslt updates

Equipment Validation

The current XML schema allows the repetition of equipment. Swimmers are allowed to swim with pads with pads. A XPath assertion is necessary to ensure that each piece of equipment can only be used once per <instruction>.

Stroke within <repetition>

Some strokes, such as IM Overlap and IM Order only make sense within a <repetition>. Modify swiML.xsd with an assertion that validates that all such strokes only occur within a repetition. In the folder bookExamples, the file strokeRepetition.xml has valid and invalid test cases.

instruction in repetition invalid

The following example give and error in validation. This is visible in jasiMasaters2024012101.xml

<!-- not valid -->
<instruction>
    <repetition>
        <repetitionCount>4</repetitionCount>
        <stroke><standardStroke>freestyle</standardStroke></stroke>
        <equipment>fins</equipment>
        <instruction>
            <length>
                <lengthAsDistance>100</lengthAsDistance>
            </length>
            <stroke>
                <drill>
                    <drillName>123</drillName>
                    <drillStroke>freestyle</drillStroke>
                </drill>
            </stroke>
        </instruction>
    </repetition>
</instruction>

<!-- valid -->
<instruction>
    <length>
        <lengthAsDistance>100</lengthAsDistance>
    </length>
    <stroke>
        <drill>
            <drillName>123</drillName>
            <drillStroke>freestyle</drillStroke>
        </drill>
    </stroke>
</instruction>

SVG logo scaling

The swiML logo on the HTML page does not scale with the rest of the text. Its size should be determined by en or em. This will make it relative to the overall text size which is the basis for all other size units used.

Data Export to plain text

Use XSLT to convert the XML to plain text that can be copied into Strava and other apps that do not handle the structure of swimming programs.

totalLength in continueType

The <continueType> should not have a <totalLength> in it. The length should be calculated in XSLT when generating the HTML/PDF. Please remove this element. If we were to have such an element, it should be called something more specific, such as <continueLength>

Please do also update <continue> documentation. It still refers to a pyramid: <xs:documentation>Instruction process element to swim a pyramid.</xs:documentation>

Data export to verbatim

For the purpose of data analysis it would be desirable to flatten out all instructions. All repetitions and other structural elements should be converted to a plain list of instructions. The resulting XML file should be have a plain table structure that can be easily imported into statistical programs. In addition, a conversation to a CSV file would be desired.

The individualMedley, individualMedleyOrder and individualMedleyOverlap will make this a bit difficult.

First Second Third

Repetitions can be subdivided. A 10 x 100 can be divided into the first five freestyle and the second five backstroke. Any number of subdivisions are possible.

simplify repetition/continue

The question is if a repetition is just a continue with a rest. If so, we could possibly simplify the whole schema.

breath in repetition causes validation error

Adding breath to an instruction inside a repetition causes a validation error. jasiMasters2024011201.xml

<!-- not valid -->
<instruction>
    <repetition>
        <repetitionCount>4</repetitionCount>
        <simplify>true</simplify>
        <equipment>fins</equipment>
        <instruction>
            <length>
                <lengthAsDistance>100</lengthAsDistance>
            </length>
            <stroke>
                <standardStroke>freestyle</standardStroke>
            </stroke>
            <breath>5</breath>
        </instruction>
    </repetition>
</instruction>

<!-- valid -->
<instruction>
    <length>
        <lengthAsDistance>100</lengthAsDistance>
    </length>
    <stroke><standardStroke>freestyle</standardStroke></stroke>
    <breath>5</breath>
</instruction>

breathing

breath cand be as every 5 or 5 times per lap. It can also be expressed as bilateral.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.