1. 23 Nov, 2016 2 commits
    • Sébastien Piat's avatar
      eppstein: new algorithm · fec365ec
      Sébastien Piat authored
      K Shortest Path algorithm implemented following the Eppstein implementation
      described in the article: `Finding the k shortest paths`, David Eppstein (1997).
      
      * tests/python/lightest.py: Test it here.
      * vcsn/algos/dijkstra-node.hh: Here.
      * vcsn/algos/eppstein.hh: Here.
      * vcsn/algos/implicit-path.hh: Here.
      * vcsn/algos/lightest.hh: Here.
      * vcsn/algos/path.hh: Here.
      * vcsn/algos/shortest-path-tree.hh: Here.
      * vcsn/local.mk: Here.
      fec365ec
    • Younes Khoudli's avatar
      tests: tracebacks: skip when IPython is too old · a386d76b
      Younes Khoudli authored
      The stack frame from IPython differs between IPython 2 and 5: there's
      one more "frame" in the former.  In fact, these "frames" include the
      lines of dashes displayed before and after the stack trace, and also
      the error message in itself.
      
      Trying to actually fix the filtering of the stack trace seems too
      painful.  Let's just skip this test with old IPythons.
      
      Fixes #145.
      
      * tests/python/tracebacks.py: here.
      a386d76b
  2. 21 Nov, 2016 5 commits
  3. 16 Nov, 2016 1 commit
  4. 15 Nov, 2016 3 commits
  5. 09 Nov, 2016 2 commits
  6. 05 Nov, 2016 1 commit
    • Akim Demaille's avatar
      doc: update NEWS.md and NEWS.mw · accf7a4c
      Akim Demaille authored
      Pandoc does a great job, but not perfect.  We need to patch the
      output.
      
      * NEWS.md: Update.
      * build-aux/bin/md-2-mw: New.
      * doc/NEWS.mw.patches/01-2.2.patch,
      * doc/NEWS.mw.patches/02-2.3.patch,
      * doc/NEWS.mw.patches/03-2.4.patch: New.
      accf7a4c
  7. 04 Nov, 2016 4 commits
    • Younes Khoudli's avatar
      random_automaton: add weights generation · 9931859a
      Younes Khoudli authored
      * vcsn/algos/random-automaton.hh: Here.
      * vcsn/dyn/algos.hh: Add the parameter to dyn
      * python/vcsn_cxx.cc: Update python bindings.
      * tests/python/factory.py: Test it.
      * doc/notebooks/context.random_automaton.ipynb: Document it.
      9931859a
    • Akim Demaille's avatar
      tests: skip when the kernel does not start · 85615f55
      Akim Demaille authored
      We have sporadic errors when checking notebooks:
      
          Traceback (most recent call last):
            File "/srv/teamcity-agent/work/a0185dad9234e013/tests/bin/ipynbdoctest.py", line 279, in <module>
              success &= test_notebook(os.path.basename(ipynb))
            File "/srv/teamcity-agent/work/a0185dad9234e013/tests/bin/ipynbdoctest.py", line 204, in test_notebook
              kc.wait_for_ready()
            File "/usr/lib/python3.5/site-packages/jupyter_client/blocking/client.py", line 59, in wait_for_ready
              raise RuntimeError('Kernel died before replying to kernel_info')
          RuntimeError: Kernel died before replying to kernel_info
      
      See https://github.com/jupyter/nbconvert/issues/277.
      
      * tests/bin/ipynbdoctest.py (test_notebook): Skip if we failed to fire
      the kernel.
      85615f55
    • Akim Demaille's avatar
      package: 2.4 · 41207e67
      Akim Demaille authored
      * configure.ac: Here.
      41207e67
    • Akim Demaille's avatar
      expressions: use static-if to handle tuple nodes · a1be9c99
      Akim Demaille authored
      So far, we were using a (partial) specialization of class templates to
      dispatch on whether are multitape or not.  Use static-if instead.
      This is still not very elegant, but it seems better than what we had.
      
      * vcsn/core/rat/copy.hh, vcsn/core/rat/hash.hh, vcsn/core/rat/info.hh,
      * vcsn/core/rat/less.hh, vcsn/core/rat/partial-identity.hh,
      * vcsn/core/rat/printer.hh vcsn/core/rat/project.hh,
      * vcsn/core/rat/size.hh, vcsn/core/rat/transpose.hh:
      Use static-if where we did not before.
      Use decltype to stop the instantiation of class templates
      by making them depend on a parameter type.
      a1be9c99
  8. 03 Nov, 2016 6 commits
    • Akim Demaille's avatar
      build: avoid warnings · 703c3f26
      Akim Demaille authored
      * vcsn/core/rat/dot.hh: Make the instantiation of visit_tuple depend
      on a template parameter to avoid instantiation when not used.  This
      could be see because we had warnings about it even in lal, b, which,
      of course, does not instantiate `visit_tuple`.
      See also http://stackoverflow.com/questions/40385953.
      But also address the warning that we see with tuples: initialize
      name_.
      703c3f26
    • Akim Demaille's avatar
      wet: add missing copy constructors, and fixes · 06d50b7f
      Akim Demaille authored
      Warnings from PVS Studio.
      Reported by Alexandre Duret-Lutz as item 12 in #140.
      
      * vcsn/misc/wet.hh: Add copy ctor to classes having an assignment
      operator.
      Use noexcept.
      Use delegating constructors rather than redundancy.
      Prefer braces.
      Properly assert impossible situations.
      06d50b7f
    • Akim Demaille's avatar
      build: address warnings from PVS Studio · 05776e25
      Akim Demaille authored
      Reported by Alexandre Duret-Lutz in #140.
      
      * vcsn/core/rat/expression.hh. vcsn/core/rat/expression.hxx
      (variadic::rbegin, variadic::rend): Remove broken, but unused.
      Was implemented as begin/end, but the type system was happy
      anyway!
      Item 32 in #140.
      (variadic, weight_node): Remove unused copy-ctor that is not
      assorted of an assignment operator.
      Items 27 and 28 in #140.
      05776e25
    • Younes Khoudli's avatar
      tools: fix error messages · 7c4ae197
      Younes Khoudli authored
      Fixes #141.
      
      The error messages were given C++ style funtion signatures, not shell
      style ones. Factor the code used to generate those and fix that.
      
      * build-aux/bin/tools-gen: Here.
      * tests/tools/evaluate.chk: Test it.
      * libexec/vcsn-tools.cc: Change last line of help messages.
      * doc/notebooks/Tools.ipynb: Update last line of help message.
      * tests/tools/help.chk: Update last line of help message.
      7c4ae197
    • Akim Demaille's avatar
      tests: fix dependencies · 7ac2b81f
      Akim Demaille authored
      * tests/unit/local.mk (score): Does depend on the libraries.
      7ac2b81f
    • Akim Demaille's avatar
      style: rename bindings-gen as oodyn-gen · 60f0a80d
      Akim Demaille authored
      * build-aux/bin/bindings-gen: Rename as...
      * build-aux/bin/oodyn-gen: this.
      * python/local.mk: Adjust.
      60f0a80d
  9. 02 Nov, 2016 8 commits
  10. 01 Nov, 2016 8 commits
    • Akim Demaille's avatar
      tests: factory: improve likeliness of passing a random test · 187522aa
      Akim Demaille authored
      * tests/python/factory.py: We don't need `!` when trying to generate a
      weight.
      187522aa
    • Akim Demaille's avatar
      expression: add the "agressive" identities level · dc844467
      Akim Demaille authored
      In particular, in this level, E{T} is E{t}.  This should help
      comparing {t} and {T} when desugaring right quotient.
      
      * vcsn/core/rat/identities.hh, lib/vcsn/rat/identities.cc
      (agressive, is_agressive): New.
      (is_distributive): Check for equality, there is no longer a
      monotonic order.
      * vcsn/core/rat/expressionset.hxx: Implement additional simplifications.
      * tests/rat/b.rat, tests/rat/q.rat: Check.
      * doc/notebooks/Expressions.ipynb: Doc.
      dc844467
    • Akim Demaille's avatar
      expression: project: fix · 135d3247
      Akim Demaille authored
      * vcsn/core/rat/project.hh: Handle compose.
      Obey the identities even with unary operators.
      (project, project_): Rename as...
      (rec_): this, for consistency with copy.
      * tests/python/project.py: Check the unary and the binary operators.
      
      fixup! expression: project: handle compose
      135d3247
    • Akim Demaille's avatar
      expression: copy: handle identities properly · ece58a55
      Akim Demaille authored
      Currently, when we copy/convert an expression, we just copy the AST,
      possibly changing the labelset and the weightset.  Unfortunately this
      means that we don't obey the new identities, and `a+a` from `none` to
      `linear`, stays `a+a`.
      
      * vcsn/core/rat/copy.hh: Don't blindly copy the tree, invoke the
      expressionset's operations.
      * tests/python/expression.py: Check this.
      ece58a55
    • Akim Demaille's avatar
      lightest-automaton: simplifications · 22016b17
      Akim Demaille authored
      * vcsn/algos/lightest-automaton.hh: Improve error message.
      Reorder the if in a more natural order.
      Don't check for null_transitions in paths, this cannot happen
      (and does not happen in the test suite).
      And use the copier's feature to copy sets of transitions.
      
      * tests/python/lightest-automaton.py: Reorder.
      Check error messages.
      (check): Simplify (there is no need to treat \z in a special way), and
      fix (the weight applies to the whole expression, not just the first
      term).
      22016b17
    • Akim Demaille's avatar
      doc: rename *.operators pages as *.Operators · 8933d19d
      Akim Demaille authored
      * doc/notebooks/automaton.operators.ipynb: Rename as...
      * doc/notebooks/automaton.Operators.ipynb: this.
      * doc/notebooks/context.operators.ipynb: Rename as...
      * doc/notebooks/context.Operators.ipynb: this.
      * doc/notebooks/context.random_weight.ipynb: .
      * doc/notebooks/expansion.operators.ipynb: Rename as...
      * doc/notebooks/expansion.Operators.ipynb: this.
      * doc/notebooks/expression.operators.ipynb: Rename as...
      * doc/notebooks/expression.Operators.ipynb: this.
      * doc/notebooks/label.operators.ipynb: Rename as...
      * doc/notebooks/label.Operators.ipynb: this.
      * doc/notebooks/polynomial.operators.ipynb: Rename as...
      * doc/notebooks/polynomial.Operators.ipynb: this.
      * doc/notebooks/weight.operators.ipynb: Rename as...
      * doc/notebooks/weight.Operators.ipynb: this.
      8933d19d
    • Akim Demaille's avatar
      doc: expansion.ldivide · 492c497d
      Akim Demaille authored
      Related to #50.
      
      * doc/notebooks/expansion.ldivide.ipynb: New.
      * doc/notebooks/expression.ldivide.ipynb,
      * doc/notebooks/expression.rdivide.ipynb: Fix: there is no need for
      LAW here.
      492c497d
    • Akim Demaille's avatar
      expression: remove dead file · 827069f0
      Akim Demaille authored
      * vcsn/core/rat/hash.hxx: Remove.
      Made useless in 97021ee8.
      827069f0