jfbercher / jupyter_latex_envs

(Some) LaTeX environments for Jupyter
Other
112 stars 28 forks source link

update to notebook 5.0 #25

Open chrisjsewell opened 7 years ago

chrisjsewell commented 7 years ago

Hey, cool package, really interested for use with my https://chrisjsewell.github.io/ipypublish/

However I notice that its Compatibiilty specification (in the yaml) is only set to notebook 4.0. When I tested it out on a notebook 5.0 (via nbextensions) its been a little buggy in terms of resolving reference links (getting some ??) and citations:

  1. I have and @online citation which doesn't resolve
  2. I have an @article that resolves as (Kirkeminde and Ren, undefined) and I'm not sure what the undefined is meant to be
  3. The reference section says it can't find the bibliography (despite it resolving the above citation)

Not sure if this is related to the version change?

Cheers

jfbercher commented 7 years ago

Hi yes, I shall update the yaml. I have tested it with notebook 5. without problems.

As noted in #22, it seems that there has been some regressions in some recent modifications that affects the bibliography. I will have a look as fast as I can, but I am quite busy these days. I would be helpful if you could upload somewhere a notebook + bib with reproducible issues. Also if you can detail the issue you mention in https://github.com/chrisjsewell/ipypublish/issues/6

Regarding your ipypublish package, we may certainly do something together (merging some ideas of ipypyblish in latex_envs and reciprocally).

chrisjsewell commented 7 years ago

Regarding the issues in chrisjsewell/ipypublish#6, I don't seem to be able to replicate them now (maybe I upgraded a package in the interim), so don't worry about that. It's mainly the reference resolving fix that would be nice:

Property 1

If all the akak in equation (??????) of definition 1 are zero, then the filter has a finite impulse response.

Proof
Let δ[n]δ[n] denote the Dirac impulse. Take x[n]=δ[n]x[n]=δ[n] in (??????). This yields, by definition, the impulse response: 

The citations I talked about are from a bib just containing:

@online{_world_2015,
  title = {World {{Oil}} and {{Gas Review}} 2015 - {{Eni}}},
  url = {http://www.eni.com/en_IT/company/culture-energy/world-oil-gas-review/world-oil-gas-review-2015.shtml},
  timestamp = {2016-05-26T16:36:27Z},
  urldate = {2016-05-25},
  date = {2015},
  file = {...}
}

@article{kirkeminde_thermodynamic_2012,
  title = {Thermodynamic Control of Iron Pyrite Nanocrystal Synthesis with High Photoactivity and Stability},
  volume = {1},
  issn = {2050-7496},
  doi = {10.1039/C2TA00498D},
  abstract = {...},
  langid = {english},
  number = {1},
  journaltitle = {Journal of Materials Chemistry A},
  shortjournal = {J. Mater. Chem. A},
  author = {Kirkeminde, Alec and Ren, Shenqiang},
  urldate = {2017-06-18},
  date = {2012-11-29},
  pages = {49--54},
  file = {...}
}
chrisjsewell commented 7 years ago

Yeh happy to collab (when we have the time!). I guess the dream is to have the ultimate hybrid of, for example, TexMaker/MS Word/Jupyter Notebook.

One thing that I would like to pick your brains on, since you have experience with nbextensions, is implementing chrisjsewell/ipypublish#1. How easy/hard it would be to have a button that, for instance, puts a coloured border around all cells that have a "latex_figure" key in their metadata or hides all cells that don't have it?

jfbercher commented 7 years ago

Various updates

chrisjsewell commented 7 years ago

Yeh brilliant ta :)

FYI, for creating html reports/presentations in ipypublish, I created a 'simple' nbconvert preprocessor to handle latex tags: https://github.com/chrisjsewell/ipypublish/blob/master/ipypublish/preprocessors/latextags_to_html.py

Its obviously not as 'complete' as yours, handling whole equation environments etc. One thing I do a little differently is that, rather than have reference section, I simply use the doi or url field to create a hyperlink directly to the source.

See here for the outcome: https://chrisjsewell.github.io/ipypublish/Example.html#References-and-Citations