Hi Genis,

Not sure if you still have problems with this..

If yes, can you also try to see what BibDocFiles are attached to the video bibdoc:

$ from invenio.bibdocfile import BibRecDocs
$ brd = BibRecDocs(6259)
$ bibdoc = brd.get_bibdoc('Demo_video')
$ bibdoc.list_all_files() # this should return a list of 3 BibDocFiles, 1 for 
master and 2 for webm slaves


If the above only returns the master, which looks like the problem you are having, this might be due to some restriction issues when trying to update the bibdoc structure, more exactly when trying to update the .md5 file. This can happen if the user process that runs the bibencode jobs does not have the necessary permissions to access the .md5 file in write mode. One thing to do in this case is to check the permissions of the .md5 file in the 243 dir. They should be the same for all files, allowing the 'www-data' user (or your apache user) to write. Another thing that you can try in order to figure out if this is the problem (since indeed the logs are not very helpful in this case) is to open ipython as superuser (so you know you have all the rights), and try to redo the list of bibdocfile attached to the Demo_video bibdoc:

$ from invenio.bibdocfile import *
$ brd = BibRecDocs(6259)
$ bibdoc = brd.get_bibdoc('Demo_video')
$ bibdoc.list_all_files() # this should show only the master
$ bibdoc._build_file_list() # this should reconstruct the list of bibdocfiles 
attached to this bibdoc
$  bibdoc.list_all_files() # should now return a list of 3 BibDocFiles, 
including the webm slaves, in which case the display should be ok

This is a simplified manner of reproducing what bibencode is doing. If this works, it means that there is a mis-configuration somewhere regarding permissions. The good thing is that since the the webm slaves are in the bibdoc folder it means that the conversion worked :-)

Cheers,
Ludmila


On 06/07/2013 05:36 PM, Genis Musulmanbekov wrote:

Hi Ludmila,


>Oh, you're probably not running latest master. In this case this should work:

>brd.get_bibdoc('Demo_video').get_base_dir()
The response:

***

<bound method BibDoc.get_base_dir of BibDoc(243, 6295, 'Demo_video', 'Main', False)>

***

The contents of dir '243' are:

Demo_video.mpg;master;1

Demo_video.webm;480p;1

Demo_video.webm;720p;1

So, why webm-files are not added to the record?

>In any case, this will only show you what it's in the folder on disk (this folder should contain the master and webm formats), it >will not solve the issue. You should check the logs (bibtask and invenio) to see if something went wrong when trying to add the >webm formats to the record after they were created.

There are no err-logs except for 'invenio.err' (which I sent you before). But I can't make clear the source of the error from its content. If it is not sufficiently informative to solve the problem, is it?

Genis


Cheers,
Ludmila



On 06/07/2013 03:37 PM, Genis Musulmanbekov wrote:

    Hi Ludmila,

    >Hi Genis,

    >You were saying in your previous email that the webm formats were
    created, but looking at this record,
    http://lt->jds.jinr.ru/record/6295
    <http://lt-%3ejds.jinr.ru/record/6295>, they have not been added
    to the record (they're not in the list of files or in the marc),
    this is why you >can not see them on the record page. Maybe some
    troubles with bibdocfile?
    >You could also check the folder where the formats for this record
    should be stored to see if they are there.

    >For finding out the location on disk:

    >from invenio.bibdocfile import BibRecDocs

    >brd = BibRecDocs(6259)

    >brd.list_bibdocs_by_names()['Demo_video'].get_base_dir()

    Yes, I run these commands and the response was

    *******

    Traceback (most recent call last):

       File "<stdin>", line 1, in <module>

    AttributeError: BibRecDocs instance has no attribute
    'list_bibdocs_by_names'

    *******

    Genis

    Cheers,
    Ludmila



    On 06/05/2013 08:23 PM, Genis Musulmanbekov wrote:

        Hi Ludmila,

        >These errors are raised when trying to interpret and display
        the bfe_video_platform_suggestions format element (used >for
        displaying detailed video pages). Unfortunately the error log
        is not detailed enough to point to the error,

        But the traceback with detailed info was in the attached
        'invenio.err' in my previous letter. I am sending it again
        (attached).

        >but you can try to debug it using ipython:

        $ipython

        In [1]: from invenio.bibformat_elements.bfe_video_platform_suggestions 
import format_element

        In [2]: from invenio.bibformat_engine import BibFormatObject

        In [3]: bfo = BibFormatObject(recid) # recid is the record id of your 
video record

        In [4]: format_element(bfo)

        This last call will probably fail, and give you the traceback
        with information on where the problem is.

        The last call

        In [4]: format_element(bfo)

        did not fail, and the response for it is

        ******

        '\n<!-- VIDEO SUGGESTION -->\n<div
        class="video_suggestion_box">\n

        <div class="video_suggestion_thumbnail">\n

        <a href="http://lt-jds.jinr.ru/record/6295";>\n

        <img
        
src="http://lt-jds.jinr.ru/record/6295/files/Demo_video_06.jpg?subformat=big";
        alt="POSTER"/>\n

        </a>\n

<div class="video_suggestion_duration">\n 11 s\n </div>\n </div>\n

        <div class="video_suggestion_title">\n  Demo video: CMS
        Detector with Heavy Ion Collision \n    </div>\n

        <div class="video_suggestion_author">\n  by JDS
        Administrator\n    </div>\n</div>\n'

        ******
        Any idea?

        Genis

        Hi Genis,

        These errors are raised when trying to interpret and display
        the bfe_video_platform_suggestions format element (used for
        displaying detailed video pages). Unfortunately the error log
        is not detailed enough to point to the error, but you can try
        to debug it using ipython:

        $ipython

        In [1]: from invenio.bibformat_elements.bfe_video_platform_suggestions 
import format_element

        In [2]: from invenio.bibformat_engine import BibFormatObject

        In [3]: bfo = BibFormatObject(recid) # recid is the record id of your 
video record

        In [4]: format_element(bfo)

        This last call will probably fail, and give you the traceback
        with information on where the problem is.

        Hope this helps!

        Cheers,
        Ludmila

        On 06/04/2013 01:55 PM, Genis Musulmanbekov wrote:

            Dear Jerome,

            > I am assuming that in your case the "assure_quality" option is

            > preventing the 'mp4' and 'webm' options to be created.
            Indeed, the

            > profiles used in the default
            "batch_template_submission.json" create

            > videos sized at minimum 854x480 (*_480P) while your input
            videos are

            > 720x576 (PAL) max. In order to validate this assumption
            you could try

            > uploading a larger video on your server, such as the demo
            one (Full

            > HD):

            > 
<http://invenio-demo.cern.ch/record/107/files/CERN-MOVIE-2010-075.mpg>

            >

            Indeed, higher quality video-files (1240x720) uploading
            resulted in conversion to webm-formats (480 and 720).
            However, they are not seen by the browser and can't be
            played. Using VIDEO SUBMISSION I uploaded demo-video
            'CERN-MOVIE-2010-075.mpg (with another name). webm-files
            are created but the result is the same.

            There are some errors given by 'invenio.err' (attached)
            starting with:

            "InvenioBibFormatError: "Error when evaluating format
            element VIDEO_PLATFORM_SUGGESTIONS with parameters
            {'threshold': '75', 'bfo':
            <invenio.bibformat_engine.BibFormatObject instance at
            0x7f9fdc0e44d0>, 'shuffle': 'True', 'maximum': '3',
            'collection': 'Videos'}."
            (bibformat_engine.py:622:eval_format_element)"

            What is the source of them?

            Genis


Reply via email to